Ldap utilities works OK. For example: ldapsearch -x -h mycompany.com -b dc=mycompany,dc=com "(sAMAccountName=gonzalezej)".
El jueves, 21 de junio de 2012 12:43:09 UTC-4:30, szimszon escribió: > > common ldap utilities are working? ldapsearch and co? > > 2012. június 21., csütörtök 17:34:45 UTC+2 időpontban ehgonzalez a > következőt írta: >> >> You rigth, python version is 2.6.6. I copied ldap_auth.py from trunk but >> it's throwing same error. >> >> any ideas? >> >> El jueves, 21 de junio de 2012 10:18:43 UTC-4:30, szimszon escribió: >>> >>> Try to use ldap_auth.py from trunk. Just copy it over the old one. >>> >>> You say Python 2.7.3 but in the error there is a >>> >>> ... python2.6/dist-packages/ldap ... >>> >>> >>> 2012. június 21., csütörtök 16:39:40 UTC+2 időpontban ehgonzalez a >>> következőt írta: >>>> >>>> Hi, >>>> >>>> When I try to import the ldap_auth module in my db.py is throwing an >>>> error. Here's the traceback: >>>> >>>> Traceback (most recent call last): >>>> File "/var/www/web2pytest/gluon/restricted.py", line 205, in restricted >>>> exec ccode in environment >>>> File "/var/www/web2pytest/applications/SMS/models/db.py" >>>> <https://web2py-test.pdvsa.com/admin/default/edit/SMS/models/db.py>, line >>>> 44, in <module> >>>> from gluon.contrib.login_methods.ldap_auth import ldap_auth >>>> File "/var/www/web2pytest/gluon/custom_import.py", line 293, in __call__ >>>> fromlist, level) >>>> File "/var/www/web2pytest/gluon/custom_import.py", line 78, in __call__ >>>> level) >>>> File "/var/www/web2pytest/gluon/contrib/login_methods/ldap_auth.py", >>>> line 9, in <module> >>>> raise e >>>> SystemError: error 89 from ldap_set_option >>>> >>>> >>>> Web2py's Shell: >>>> >>>> In [1] : import ldap >>>> >>>> In [2] : import ldap.filter >>>> >>>> In [3] : ldap.set_option( ldap.OPT_REFERRALS, 0 ) >>>> Traceback (most recent call last): >>>> File "/var/www/web2py/gluon/contrib/shell.py", line 225, in run >>>> exec compiled in statement_module.__dict__ >>>> File "<string>", line 1, in <module> >>>> File "/usr/lib/python2.6/dist-packages/ldap/functions.py", line 124, in >>>> set_option >>>> _ldap_function_call(_ldap.set_option,option,invalue) >>>> File "/usr/lib/python2.6/dist-packages/ldap/functions.py", line 57, in >>>> _ldap_function_call >>>> result = func(*args,**kwargs) >>>> SystemError: error 89 from ldap_set_option >>>> >>>> Debian 6.0.5, Apache 2.2.16, WSGI 3.3-2, Python 2.7.3, , web2py 1.99.7. >>>> >>>> Any help much appreciated. >>>> >>>> Eduardo. >>>> >>>> >>>> >>>> >>>> >>>> >>>> --

