Skip to content
Snippets Groups Projects
Commit ff45434b authored by Niklas Keller's avatar Niklas Keller
Browse files

Use constant type comparison for hashes, fixes #2132

parent c5d5fc7e
No related branches found
No related tags found
Loading
......@@ -91,7 +91,7 @@ class PassHash {
//crypt and compare
$call = 'hash_'.$method;
$newhash = $this->$call($clear, $salt, $magic);
if($newhash === $hash) {
if(\hash_equals($newhash, $hash)) {
return true;
}
return false;
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment