[Date Prev][Date Next] [Chronological] [Thread] [Top]

Re: authentification issue with clear text password

On Wed, 15 Feb 2012 13:38:17 +0200, "Szilard Gyorgy" <szilard@gyorgy.net> wrote:
ldapcompare -D "uid=testuser,ou=Users,dc=domain,dc=net" -w test
"uid=testuser,ou=Users,dc=domain,dc=net" -v userPassword:test

Why are you using compare at all?  The server already checked
the password when it accepted your Bind with -D and -w <password>.
I don't think there's an ldap tool which does nothing but Bind,
so you have to ask it to do something afterwards but it doesn't
really matter what.  In such cases I usually use ldapwhoami:

   ldapwhoami -x -D "uid=testuser,ou=Users,dc=domain,dc=net" -w test

The -x disables SASL, which you do not use or want with -D/-w.
SASL is on by default if you have compiled in support for it.

BTW, maybe you want to use -y <file> for the password instead.
Note that the file contents must NOT end with a newline, unless
the newline is part of the password.