Skip to content
This repository has been archived by the owner on Jan 8, 2020. It is now read-only.

Commit

Permalink
add . to valid bcrypt hash charlist
Browse files Browse the repository at this point in the history
  • Loading branch information
stefanotorresi committed Mar 17, 2015
1 parent 63a2317 commit 7a35320
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion library/Zend/Crypt/Password/Apache.php
Expand Up @@ -141,7 +141,7 @@ public function verify($password, $hash)
return Utils::compareStrings($hash, $hash2);
}

$bcryptPattern = '/\$2[ay]?\$[0-9]{2}\$[' . addcslashes(static::BASE64, '+/') . ']{53}/';
$bcryptPattern = '/\$2[ay]?\$[0-9]{2}\$[' . addcslashes(static::BASE64, '+/') . '\.]{53}/';

if (strlen($hash) > 13 && ! preg_match($bcryptPattern, $hash)) { // digest
if (empty($this->userName) || empty($this->authName)) {
Expand Down

0 comments on commit 7a35320

Please sign in to comment.