Use hash_equals method to compare the hashes.
This commit is contained in:
@@ -44,7 +44,7 @@ class CourierSHA1 implements HashAlgorithm
|
||||
*/
|
||||
public function checkPassword($password, $dbHash)
|
||||
{
|
||||
return $this->getPasswordHash($password) === $dbHash;
|
||||
return hash_equals($dbHash, $this->getPasswordHash($password));
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
Reference in New Issue
Block a user