[python-ldap] sAMAccountName in DN for Bind
Michael Ströder
michael at stroeder.com
Mon Apr 22 19:10:06 CEST 2013
Anurag Chourasia wrote:
> Is *sAMAccountName *not allowed in the DN for bind operation?
What is allowed in a DB is entirely up to the server's schema checking.
So this is a question you have to ask the LDAP server vendor.
> If i use a DN = "*CN=Guddu,OU=Users,OU=Central,OU=CL,DC=company,DC=corp*" then
> I am able to bind and do a search operation also.
>
> However, if i use a DN=
> "*sAMAccountName=Guddu,OU=Users,OU=Central,OU=CL,DC=company,DC=corp*" then i
> get a *ldap.INVALID_CREDENTIALS* error
Does entry
sAMAccountName=Guddu,OU=Users,OU=Central,OU=CL,DC=company,DC=corp
actually exist.
I suspect you expect some special magic which isn't there.
But better ask your LDAP server vendor.
> I can confirm that the user has the attribute *sAMAccountName=Guddu *for sure.
That's not how LDAP simple bind works in general.
There is some special non-standard feature in AD to use the user's principal
name in a simple bind request. Not sure whether that works with ADAM though.
Ciao, Michael.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: smime.p7s
Type: application/pkcs7-signature
Size: 3883 bytes
Desc: S/MIME Cryptographic Signature
URL: <http://mail.python.org/pipermail/python-ldap/attachments/20130422/3c301d07/attachment.bin>
More information about the python-ldap
mailing list