|
@@ -322,8 +322,10 @@ class BCryptSHA256PasswordHasher(BasePasswordHasher):
|
|
|
|
|
|
|
|
|
data = force_bytes(data)
|
|
|
+
|
|
|
+ hashpw = force_bytes(bcrypt.hashpw(password, data))
|
|
|
|
|
|
- return constant_time_compare(data, bcrypt.hashpw(password, data))
|
|
|
+ return constant_time_compare(data, hashpw)
|
|
|
|
|
|
def safe_summary(self, encoded):
|
|
|
algorithm, empty, algostr, work_factor, data = encoded.split('$', 4)
|