Commit 3c6d225c authored by Daniele Venzano's avatar Daniele Venzano
Browse files

Fix authentication

parent 609ca6a1
......@@ -72,9 +72,11 @@ def get_auth(handler: ZoeRequestHandler):
# First of all try to authenticate against a fixed list of users in a text file
authenticator = PlainTextAuthenticator() # type: BaseAuthenticator
uid, role = authenticator.auth(username, password)
if uid is not None:
uid, role = authenticator.auth(username, password)
return uid, role
except zoe_api.exceptions.ZoeAuthException:
# It it fails, continue with the normal authentication
if get_conf().auth_type == 'ldap':
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment