Skip to content
Snippets Groups Projects
Commit 72937d84 authored by Alexandre Ferland's avatar Alexandre Ferland Committed by GitHub
Browse files

Merge pull request #26 from krmarien/master

Fix set_option call to LDAP for SSL CERT
parents 348be0b9 d2f52b16
No related branches found
No related tags found
No related merge requests found
...@@ -67,9 +67,9 @@ class LDAP(object): ...@@ -67,9 +67,9 @@ class LDAP(object):
if app.config['LDAP_REQUIRE_CERT']: if app.config['LDAP_REQUIRE_CERT']:
ldap.set_option(ldap.OPT_X_TLS_REQUIRE_CERT, ldap.set_option(ldap.OPT_X_TLS_REQUIRE_CERT,
ldap.OPT_X_TLS_DEMAND, ldap.OPT_X_TLS_DEMAND)
(ldap.OPT_X_TLS_CACERTFILE, ldap.set_option(ldap.OPT_X_TLS_CACERTFILE,
current_app.config['LDAP_CERT_PATH'])) current_app.config['LDAP_CERT_PATH'])
for option in ['USERNAME', 'PASSWORD', 'BASE_DN']: for option in ['USERNAME', 'PASSWORD', 'BASE_DN']:
if app.config['LDAP_{0}'.format(option)] is None: if app.config['LDAP_{0}'.format(option)] is None:
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment