mirror of
https://github.com/Mikaela/Limnoria.git
synced 2025-11-27 05:07:30 +01:00
src/ircdb: checkPassword should return false when password is None instead of trying to continue with the check.
This commit is contained in:
parent
d074721603
commit
9c34b231aa
@ -255,6 +255,8 @@ class IrcUser(object):
|
|||||||
|
|
||||||
def checkPassword(self, password):
|
def checkPassword(self, password):
|
||||||
"""Checks the user's password."""
|
"""Checks the user's password."""
|
||||||
|
if password is None:
|
||||||
|
return False
|
||||||
if self.hashed:
|
if self.hashed:
|
||||||
(salt, _) = self.password.split('|')
|
(salt, _) = self.password.split('|')
|
||||||
return (self.password == utils.saltHash(password, salt=salt))
|
return (self.password == utils.saltHash(password, salt=salt))
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user