more test
This commit is contained in:
parent
820ba32ea3
commit
2dc23384f3
|
@ -34,6 +34,7 @@ class LDAPUserManager(FilebasedUserManager,
|
||||||
|
|
||||||
|
|
||||||
def check_auth(self, username, password):
|
def check_auth(self, username, password):
|
||||||
|
self._logger.error("CAMERON 2")
|
||||||
if username in [None, ''] or password in [None, '']:
|
if username in [None, ''] or password in [None, '']:
|
||||||
return None
|
return None
|
||||||
ldap_conn = ldap3.Connection(LDAP_SERVER, auto_bind=ldap3.AUTO_BIND_TLS_BEFORE_BIND)
|
ldap_conn = ldap3.Connection(LDAP_SERVER, auto_bind=ldap3.AUTO_BIND_TLS_BEFORE_BIND)
|
||||||
|
@ -99,6 +100,7 @@ class LDAPUserManager(FilebasedUserManager,
|
||||||
#If user not exists in local database, search it on LDAP
|
#If user not exists in local database, search it on LDAP
|
||||||
if userid and not local_user:
|
if userid and not local_user:
|
||||||
#Return a fake user instance
|
#Return a fake user instance
|
||||||
|
self._logger.error("CAMERON 1")
|
||||||
return User(userid, str(uuid.uuid4()), True, ["user"])
|
return User(userid, str(uuid.uuid4()), True, ["user"])
|
||||||
|
|
||||||
else :
|
else :
|
||||||
|
|
Loading…
Reference in New Issue
Block a user