mirror of
https://gitlab2.federez.net/re2o/re2o
synced 2024-11-27 15:12:25 +00:00
fix crypt password verification function
This commit is contained in:
parent
375d3fbd34
commit
074b944246
1 changed files with 1 additions and 1 deletions
|
@ -115,7 +115,7 @@ class CryptPasswordHasher(hashers.BasePasswordHasher):
|
||||||
"""
|
"""
|
||||||
assert encoded.startswith(self.algorithm)
|
assert encoded.startswith(self.algorithm)
|
||||||
salt = hash_password_salt(encoded)
|
salt = hash_password_salt(encoded)
|
||||||
return constant_time_compare(crypt.crypt(password, salt),
|
return constant_time_compare(self.algorithm + crypt.crypt(password, salt),
|
||||||
encoded)
|
encoded)
|
||||||
|
|
||||||
def safe_summary(self, encoded):
|
def safe_summary(self, encoded):
|
||||||
|
|
Loading…
Reference in a new issue