[python3-ldap] < Urgent Help Needed >
Abhay Mannur
abhay.mannur at charlotterusse.com
Mon Aug 11 21:33:07 CEST 2014
Hi All,
I have successfully installed following :
Pip freeze output :
Django==1.6.5
cx-Oracle==5.1.3
django-auth-ldap==1.2.0 ( I think I don't need this - Please confirm )
pyasn1==0.1.7
python3-ldap==0.9.5
>From Python shell I do following in the sequence :
from ldap3 import Server, Connection, AUTH_SIMPLE, STRATEGY_SYNC, STRATEGY_ASYNC_THREADED, SEARCH_SCOPE_WHOLE_SUBTREE, GET_ALL_INFO
s = Server('Our LDAP server', port = 636, use_ssl = True, get_info = GET_ALL_INFO)
c = Connection(s, auto_bind = True, client_strategy = STRATEGY_SYNC, user=<My user name>, password=<My Password>, authentication=AUTH_SIMPLE, check_names=True)
Connection fails with invalid credentials error but after I execute connection command, I get s.info showing me all server details.
My windows/network admin tells me following :
It does look like you're are connecting to the LDAP server and querying basic information.
Typically I look for a couple things in a configuration file to make sure it binds properly (authenticated).
* Server name - OK
* Port
o 636 (SSL)
o I see you have this already
* Base DN
o DC=CRUSSE,DC=local
o Even though it's querying the default naming context, typically you have to specify this information in your configuration file or connection string.
* Username Attribute
o sAMAccountName
o Because LDAP isn't always Active Directory you typically have to specify what the attribute is for the username.
* Bind User DN
o CN=Abhay Mannur,OU=Users,OU=IT,OU=San Francisco,OU=Sites,OU=Charlotte Russe,DC=CRUSSE,DC=local
o Typically we enter in a service account here, but you can use your credentials for now.
* Bind User Password
o ********
o Your AD password
It looks like you may be missing the username attribute and/or not entering in the full bind DN. Again, the bind User DN would typically be a service account.
Is there a configuration file anywhere or is everything just getting specified as a parameter when connecting?
I'm totally lost with as doing LDAP authentication for the first time.
Please help me with this configuration and/or my connection object parameters etc.
Thanks,
Abhay Mannur
Programmer Analyst III
abhay.mannur at charlotterusse.com
Office : 415-820-6541
Cell : 415-279-9565
[cid:image001.jpg at 01CEC9C0.04FD8370]
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/python3-ldap/attachments/20140811/e57c002f/attachment.html>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: image001.jpg
Type: image/jpeg
Size: 2509 bytes
Desc: image001.jpg
URL: <http://mail.python.org/pipermail/python3-ldap/attachments/20140811/e57c002f/attachment.jpg>
More information about the python3-ldap
mailing list