Add a sasluser argument if a specific identity is required for the
backend, which if unsupplied, tries to guess if a binddn is present.
(Uwe's previous commit fixed EXTERNAL and GSSAPI, which did work, but
randomly failed due to hash ordering.)
Minor style cleanups, remove duplicate/unecessary logic for anonymous
binds.
FossilOrigin-Name: b2bc73d1b624235cf17da960a5e3fd0df9c0ed714bc5f71db2cbea6009f255d5
When a sasl parameter is given (and used) the password parameter is not
used by Net::LDAP. If indeed a password is required it has to be passed
in the Authen::SASL object, not as parameter to bind.
So drop the password parameter which stops trying (and failing) to use
password authentication sometimes if in Net/LDAP.pm the iteration over
%ptype hits its 'password' member before the 'sasl' member.
FossilOrigin-Name: b4e59a307c07b9a201ddd841cca963f689b424ad9e2ba6eb3f6522c955d722ad
Reset isearch state on ctrl+c when using Readline 7
Approved-by: Mahlon E. Smith <mahlon@martini.nu>
FossilOrigin-Name: 3cda1c11ffaae15eda9c530b16cc8881c58ad1bd5b769583ff9b6876a05e28bc
This change does not affect Readline versions below 7.
A fix for RL<7 would be to modify readline_state to turn off
ISEARCH and set DONE, but changing these values through the
Perl module does not appear to have visible effect.
FossilOrigin-Name: aafd253afe473a0a262860698a5a43e4db4d990565b353e6c1399ffc4c6658b5
- Print current configfile in the output of 'env' (this also makes configfile changeable in runtime via 'setenv')
- In 'configfile' commands, print which config file is being used
- Fix behavior of existing 'more_conf'
- Make load_config() return filename and hash, rather than unconditionally overwrite $conf
- Bring back %conf2 into implementation of save_config; it is necessary to be there or 'configfile' is getting lost/deleted in the runtime config
Other changes
- Add 'set' as alias for 'setenv'
- Add unsetenv/unset (opposite of setenv/set)
- Do not print unset/undefined values in 'env'
FossilOrigin-Name: 7b35ca141e0dfc74d5165f49f9fd117fffd40c7f33e05bcb9bc0c5a14736bd98
This commit enables getopt case sensitivity and adds all command line
options/abbreviations typically supported by LDAP clients:
-w/-y, -p, -x, -Z/-ZZ, -v
FossilOrigin-Name: 5f3778ecf065e9bcf061b8b6a7e606dbb3a043169a03a7630c960f331d68d6b2
- 'env' now prints 'attributes' array
- 'env' output now supports any data type, not just strings
- option --attributes on command line properly overrides config values
The remaining thing to do is to support 'setenv' to work with non-strings too.
FossilOrigin-Name: 49c1455637cbce37e0b68a4e7c7286e51f2b6401a98e11f630db3c88f737821a
This change brings output of 'ls -l' closer to the actual shell command.
FossilOrigin-Name: 7f38c81ca4c4844eae37e5450b3bda2f4bfdf4a68c840b81f3f2cd963bc0473d
- Make every command's POD doc have a single-line introductory description.
This help is then used as a one-liner summary in Term::Shell.
- Tie %cmd_map to IxHash to preserve hash elements' order.
- Fix bug in Term::Shell's code related to command aliases.
(Also emailed Term::Shell author to include the fix in next release.)
- Remove run_() which already exists in Term::Shell.
- Use Term::Shell's help facilities instead of manually redefining
run_help() and other related commands. The complete POD documentation is
still available for viewing if user invokes ./shelldap --help.
- Completer functions are disabled right now (fix coming in the next
commit)
FossilOrigin-Name: a3bfbcceb8e471a3397b5e90cfe9bd0fa7ebe84934de738e34bc620a24f7fe5c
Make Ctrl+C behave like in the shell (abort current line, redisplay)
Add '?' and 'man' as aliases for help
Add qw// on module 'use's to not import any symbols
FossilOrigin-Name: fc4cb91774beb03f371ad04c5b26e45f6db49ae40af72bb2fbccc6c3c1a65e6f
With this change, 'inspect'ing an element prints its attributes
in a defined order: (requiredness, multivaluedness)
Previously, the order was alphabetical and varying.
FossilOrigin-Name: bb3518297cc3ffdd6a8a1db79e681431f56f6d395f5300e6f99d0f444fc5fd04
%cmd_map was previously a hash containing:
{
real_function => alias_function,
...
}
Now the structure of the hash is:
{
alias_or_real_func => [ real_func/if_any, autocompleter_func ],
...
}
This allows for a more streamlined definition of commands and aliases,
and makes it possible to keep all data in %cmd_map instead of having
additional special cases.
FossilOrigin-Name: ea3c724d1676d6f2ddfddfce22c3d32135ab20d26e81f10c39c4c10bc902b5e9
POD documentation has been modified to list available shell commands using =head2
instead of =item.
This, combined with run_help() modified to accept arguments, allows one to use
'help <command name>' to get help for a specific command, similar/equal to getting
help for shell builtins in regular shells.
E.g.:
help cat
help list
FossilOrigin-Name: 94e02e094f07f261abc084b1271832ee7640053397b1e32c7d6c72d452611986
Previously, when autogenerating the config file, the name of config
itself was included in the YAML contents.
This in turn caused the config file to be re-parsed again and any
command line arguments were overwritten with values from the config
file.
Now the name of config file is not dumped if it is equal to the file
being written, and the config file is not reparsed if it is the same
file.
FossilOrigin-Name: 9c4483633c8bcf36f4e98ce41ab0f54ea4620a4b7f21ccf07e563e49afbe0da6
This commit changes the default attribute list from a fixed '*'
to a configurable list, defaulting to ['*'].
It allows one to use config file or command line to set default
attributes to retrieve and display - i.e. to set default attributes
to '+' or to a list of multiple specific attributes.
Printing or changing this value through env/setenv is currently not
supported because env/setenv only work properly with string values
while attributes is a list.
FossilOrigin-Name: 8c312e181611c61d43a588d2aa2c6e3d231db490c29f40aee861a0e1832039fc