fix: Remove deprecated option OPT_X_TLS

This commit is contained in:
Jérôme BECOT 2022-12-10 23:32:12 +01:00
parent ce4447bb12
commit 8d5b92402d
No known key found for this signature in database
GPG Key ID: 6667C39A7C2DBD6F

View File

@ -125,7 +125,6 @@ class User(db.Model):
conn = ldap.initialize(Setting().get('ldap_uri')) conn = ldap.initialize(Setting().get('ldap_uri'))
conn.set_option(ldap.OPT_REFERRALS, ldap.OPT_OFF) conn.set_option(ldap.OPT_REFERRALS, ldap.OPT_OFF)
conn.set_option(ldap.OPT_PROTOCOL_VERSION, 3) conn.set_option(ldap.OPT_PROTOCOL_VERSION, 3)
conn.set_option(ldap.OPT_X_TLS, ldap.OPT_X_TLS_DEMAND)
conn.set_option(ldap.OPT_X_TLS_DEMAND, True) conn.set_option(ldap.OPT_X_TLS_DEMAND, True)
conn.set_option(ldap.OPT_DEBUG_LEVEL, 255) conn.set_option(ldap.OPT_DEBUG_LEVEL, 255)
conn.protocol_version = ldap.VERSION3 conn.protocol_version = ldap.VERSION3