Fix the authentication behavior with non-existing users

master
kaiyou 7 years ago
parent b676366a1d
commit 6e61500eb1

@ -11,7 +11,7 @@ STATUSES = {
"authentication": ("Authentication credentials invalid", { "authentication": ("Authentication credentials invalid", {
"imap": "AUTHENTICATIONFAILED", "imap": "AUTHENTICATIONFAILED",
"smtp": "535 5.7.8", "smtp": "535 5.7.8",
"pop3": "" "pop3": "-ERR Authentication failed"
}), }),
} }
@ -52,7 +52,6 @@ def handle_authentication(headers):
"Auth-Server": server, "Auth-Server": server,
"Auth-Port": port "Auth-Port": port
} }
else:
status, code = get_status(protocol, "authentication") status, code = get_status(protocol, "authentication")
return { return {
"Auth-Status": status, "Auth-Status": status,
@ -60,7 +59,6 @@ def handle_authentication(headers):
"Auth-Wait": 0 "Auth-Wait": 0
} }
# Unexpected # Unexpected
else:
return {} return {}

Loading…
Cancel
Save