Daniele Procida wrote: > I'm trying to get django.contrib.auth.ldapauth.LDAPBackend - from: > > <http://code.djangoproject.com/attachment/ticket/2507/ldapauth.py> > > working with our LDAP server. > > IWe need TLS before the server will permit us to exchange a password with it. > > According to the documentation, we should be able to set LDAP_OPTIONS > along with the other settings: > > ``LDAP_OPTIONS`` -- hash, python-ldap global options and their values > {ldap.OPT_X_TLS_CACERTDIR: '/etc/ldap/ca/'} > > However, if we set any value in LDAP_OPTIONS (other than 'None' - and > even the one in the example above) we get an error: > > Exception Value: > 'dict' object has no attribute 'LDAP_OPTIONS' > Exception Location: > /usr/lib/python2.5/site-packages/django/contrib/auth/ldapauth.py in > authenticate, line 113 > > The full error is at: <http://dpaste.com/84838/> > > How can we set LDAP_OPTIONS to turn on TLS? > Hello,
LDAP_OPTIONS should be defined in your settings.py. Paste what you have in your settings.py for the ldap configuration, and I can help diagnose. Jeff Anderson
signature.asc
Description: OpenPGP digital signature