diff --git a/README.md b/README.md index b79cee2..25ea443 100644 --- a/README.md +++ b/README.md @@ -2,7 +2,7 @@ ![GitHub Release](https://img.shields.io/github/v/release/Macmod/godap) ![](https://img.shields.io/github/go-mod/go-version/Macmod/godap) ![](https://img.shields.io/github/languages/code-size/Macmod/godap) ![](https://img.shields.io/github/license/Macmod/godap) ![](https://img.shields.io/github/actions/workflow/status/Macmod/godap/release.yml) [![Go Report Card](https://goreportcard.com/badge/github.com/Macmod/godap)](https://goreportcard.com/report/github.com/Macmod/godap) ![GitHub Downloads](https://img.shields.io/github/downloads/Macmod/godap/total) -`godap` is a complete TUI for LDAP. +

A complete TUI for LDAP.

# Summary @@ -17,16 +17,6 @@ * [Acknowledgements](#acknowledgements) * [Disclaimers](#disclaimers) -# Screenshots - -![images/page1.png](images/page1.png) - -![images/page2.png](images/page2.png) - -![images/page3.png](images/page3.png) - -![images/page4.png](images/page4.png) - # Features * 🗒ī¸ Formats date/time, boolean and other categorical attributes into readable text @@ -37,6 +27,7 @@ * đŸ‘Ĩ Group members & user groups lookup * 🎡 Supports creation, editing and removal of objects and attributes * 🚙 Supports moving and renaming objects +* 🗑ī¸ Supports searching deleted & recycled objects * 📁 Supports exporting specific subtrees of the directory into JSON files * 🕹ī¸ Interactive userAccountControl editor * đŸ”Ĩ Interactive DACL editor @@ -102,6 +93,8 @@ You can also change the address of your proxy using the `l` keybinding. * `-L`,`--limit` - Number of attribute values to render for multi-value attributes when `-expand` is `true` (default: `20`) * `-F`,`--format` - Format attributes into human-readable values (default: `true`, to change use `-format=false`) * `-M`,`--cache` - Keep loaded entries in memory while the program is open and don't query them again (default: `true`) +* `-D`,`--deleted` - Include deleted objects in all queries performed (default: `false`) +* `-T`,`--timeout` - Timeout for LDAP connections in seconds (default: `10`) * `-I`,`--insecure` - Skip TLS verification for LDAPS/StartTLS (default: `false`) * `-S`,`--ldaps` - Use LDAPS for initial connection (default: `false`) * `-G`,`--paging` - Paging size for regular queries (default: `800`) @@ -113,34 +106,50 @@ You can also change the address of your proxy using the `l` keybinding. ## Keybindings -| Keybinding | Context | Action | -| --------------------------------- | ----------------------------------------------------------------- | ------------------------------------------------------------- | -| `Ctrl` + `Enter` (or `Ctrl` + `J`) | Global | Next panel | -| `f` / `F` | Global | Toggle attribute formatting | -| `e` / `E` | Global | Toggle emojis | -| `c` / `C` | Global | Toggle colors | -| `a` / `A` | Global | Toggle attribute expansion for multi-value attributes | -| `l` / `L` | Global | Change current server address & credentials | -| `Ctrl` + `r / R` | Global | Reconnect to the server | -| `Ctrl` + `u / U` | Global | Upgrade connection to use TLS (with StartTLS) | -| `r` / `R` | Explorer panel | Reload the attributes and children of the selected object | -| `Ctrl` + `n / N` | Explorer panel | Create a new object under the selected object | -| `Ctrl` + `s / S` | Explorer panel | Export all loaded nodes in the selected subtree into a JSON file | -| `Ctrl` + `p / P` | Explorer panel | Change the password of the selected user or computer account | -| `Ctrl` + `a / A` | Explorer panel | Update the userAccountControl of the object interactively | -| `Ctrl` + `l / L` | Explorer panel | Move the selected object to another location | -| `Delete` | Explorer panel | Delete the selected object | -| `r` / `R` | Attributes panel | Reload the attributes for the selected object | -| `Ctrl` + `e / E` | Attributes panel | Edit the selected attribute of the selected object | -| `Ctrl` + `n / N` | Attributes panel | Create a new attribute in the selected object | -| `Delete` | Attributes panel | Delete the selected attribute of the selected object | -| `Ctrl` + `o / O` | DACL page | Change the owner of the current DACL | -| `Ctrl` + `k / K` | DACL page | Change the control flags of the current DACL | -| `Ctrl` + `n / N` | DACL entries panel | Create a new ACE in the current DACL | -| `Ctrl` + `e / E` | DACL entries panel | Edit the selected ACE of the current DACL | -| `Delete` | DACL entries panel | Deletes the selected ACE of the current DACL | -| `h` / `H` | Global | Show/hide headers | -| `q` | Global | Exit the program | +| Keybinding | Context | Action | +| --------------------------------- | ----------------------------------------------------------------- | ------------------------------------------------------------------------------- | +| Ctrl + Enter (or Ctrl + J) | Global | Next panel | +| f / F | Global | Toggle attribute formatting | +| e / E | Global | Toggle emojis | +| c / C | Global | Toggle colors | +| a / A | Global | Toggle attribute expansion for multi-value attributes | +| d / D | Global | Toggle "include deleted objects" flag | +| l / L | Global | Change current server address & credentials | +| Ctrl + r / R | Global | Reconnect to the server | +| Ctrl + u / U | Global | Upgrade connection to use TLS (with StartTLS) | +| Right Arrow | Explorer panel | Expand the children of the selected object | +| Left Arrow | Explorer panel | Collapse the children of the selected object | +| r / R | Explorer panel | Reload the attributes and children of the selected object | +| Ctrl + n | Explorer panel | Create a new object under the selected object | +| Ctrl + s | Explorer panel | Export all loaded nodes in the selected subtree into a JSON file | +| Ctrl + p | Explorer panel | Change the password of the selected user or computer account | +| Ctrl + a | Explorer panel | Update the userAccountControl of the object interactively | +| Ctrl + l | Explorer panel | Move the selected object to another location | +| Delete | Explorer panel | Delete the selected object | +| r / R | Attributes panel | Reload the attributes for the selected object | +| Ctrl + e | Attributes panel | Edit the selected attribute of the selected object | +| Ctrl + n | Attributes panel | Create a new attribute in the selected object | +| Delete | Attributes panel | Delete the selected attribute of the selected object | +| Ctrl + o | DACL page | Change the owner of the current DACL | +| Ctrl + k | DACL page | Change the control flags of the current DACL | +| Ctrl + n | DACL entries panel | Create a new ACE in the current DACL | +| Ctrl + e | DACL entries panel | Edit the selected ACE of the current DACL | +| Delete | DACL entries panel | Deletes the selected ACE of the current DACL | +| h / H | Global | Show/hide headers | +| q | Global | Exit the program | + +## Tree Colors + +The nodes in the explorer tree are colored as follows: + +| Scenario | Color | +| --------------------------------------- | -------------- | +| Object exists and is enabled | Default | +| Object exists and is disabled | Yellow\* | +| Object was deleted and not yet recycled | Gray\* | +| Object was recycled already | Red\* | + +\* Before v2.2.0, disabled nodes were colored red. This was the only custom color in the tree panel; other nodes were colored with default colors (the "include deleted objects" flag had not been implemented yet). # Contributing @@ -159,7 +168,6 @@ Contributions are welcome by [opening an issue](https://github.com/Macmod/godap/ * Although some features might work with OpenLDAP (mainly in the explorer/search pages), the main focus of this tool is Active Directory. * All features were tested and seem to be working properly on a Windows Server 2019, but this tool is highly experimental and I cannot test it extensively - I don't take responsibility for modifications that you execute and end up impacting your environment. If you observe any unexpected behaviors please [let me know](https://github.com/Macmod/godap/issues/new) so I can try to fix it. -* I'm not prioritizing Kerberos authentication at the moment. Although `ldapper` (which was a great source of inspiration and useful code) supports it, the `ldapper` authors chose to rewrite lots of dependencies maintained by third parties in order to provide this feature. This does not seem like the best approach in terms of long-term support. Nonetheless, `go-ldap` (which is godap's main dependency) currently has [an open issue](https://github.com/go-ldap/ldap/issues/115) from 2017 regarding the lack of GSSAPI support. A pull request [has been merged](https://github.com/go-ldap/ldap/pull/402) in 2022 to deal with the issue on Windows platforms only, but that isn't a suitable option for this tool. I hope someone finds a solution for this issue (maybe [go-ldap/ldap/pull/449](https://github.com/go-ldap/ldap/pull/449)) that doesn't involve rewriting dependencies I won't have time to maintain :-) # License diff --git a/TODO.md b/TODO.md index 01cbef4..688b0cc 100644 --- a/TODO.md +++ b/TODO.md @@ -1,11 +1,9 @@ # TODO (priority) -* Fix: TUI colors should be predictable to avoid strange colors in custom terminals -* Feature: Find deleted objects in Object Search -* Feature: Predefined query for legacy password fields in Object Search -* Feature: Custom themes +* Feature: Kerberos authentication +* Feature: "Information Finder" able to look up attribute names and values with regex "magically" across all cached objects in either explorer or object search +* Feature: Ctrl+S, Ctrl+L and Delete should work in object search * Feature: Load initial cache from file -* Feature: Attributes viewer in Object Search * Feature: Monitor object for real-time changes # TODO (later) @@ -13,5 +11,5 @@ * Feature: Improve object creation form (implement customizations) * Feature: Utilities for group policy manipulation * Feature: Some way to copy data from panels -* Feature: Kerberos authentication +* Feature: Custom themes * Feature: Customizable keybindings diff --git a/help.go b/help.go index 867fbb2..ae607a5 100644 --- a/help.go +++ b/help.go @@ -18,18 +18,22 @@ func initHelpPage() { | (___) || (___) || (__/ )| ) ( || ) (_______)(_______)(______/ |/ \||/ -v2.1.0 +v2.2.0 ` keybindings := [][]string{ - {"Ctrl + J", "Global", "Next panel"}, + {"Ctrl + Enter", "Global", "Next panel"}, {"f / F", "Global", "Toggle attribute formatting"}, {"e / E", "Global", "Toggle emojis"}, {"c / C", "Global", "Toggle colors"}, {"a / A", "Global", "Toggle attribute expansion for multi-value attributes"}, + {"d / D", "Global", "Toggle \"include deleted objects\" flag"}, {"l / L", "Global", "Change current server address & credentials"}, - {"r / R", "Global", "Reconnect to the server"}, - {"u / U", "Global", "Upgrade connection to use TLS (with StartTLS)"}, + {"Ctrl + r / R", "Global", "Reconnect to the server"}, + {"Ctrl + u / U", "Global", "Upgrade connection to use TLS (with StartTLS)"}, + {"Left Arrow", "Explorer panel", "Collapse the children of the selected object"}, + {"Right Arrow", "Explorer panel", "Expand the children of the selected object"}, + {"r / R", "Explorer panel", "Reload the attributes and children of the selected object"}, {"Ctrl + n / N", "Explorer panel", "Create a new object under the selected object"}, {"Ctrl + s / S", "Explorer panel", "Export all loaded nodes in the selected subtree into a JSON file"}, {"Ctrl + p / P", "Explorer panel", "Change the password of the selected user or computer account"},