diff --git a/fiches/management/commands/_ldap.py b/fiches/management/commands/_ldap.py index 8470f73..3738376 100644 --- a/fiches/management/commands/_ldap.py +++ b/fiches/management/commands/_ldap.py @@ -25,16 +25,9 @@ class LDAP: def __init__(self): """ Initialize the LDAP object """ - ldap.set_option(ldap.OPT_X_TLS_REQUIRE_CERT, ldap.OPT_X_TLS_NEVER) self.ldap_obj = ldap.initialize( "{PROTOCOL}://{URL}:{PORT}".format(**self.LDAP_SERVER) ) - self.ldap_obj.set_option(ldap.OPT_REFERRALS, 0) - self.ldap_obj.set_option(ldap.OPT_PROTOCOL_VERSION, 3) - self.ldap_obj.set_option(ldap.OPT_X_TLS, ldap.OPT_X_TLS_DEMAND) - self.ldap_obj.set_option(ldap.OPT_X_TLS_DEMAND, True) - self.ldap_obj.set_option(ldap.OPT_NETWORK_TIMEOUT, 10) - self.ldap_obj.set_option(ldap.OPT_TIMEOUT, 10) def search(self, filters="(objectClass=*)"): """Do a ldap.search_s with the given filters, as specified for