fix verify password methode ssha
Cadoles/hydra-sql/pipeline/pr-develop Build started... Details
Cadoles/hydra-sql/pipeline/head This commit looks good Details

This commit is contained in:
Rudy Masson 2023-01-11 10:30:24 +01:00
parent 4b360cc2a0
commit 39829ca6a1
1 changed files with 2 additions and 2 deletions

View File

@ -47,8 +47,8 @@ class PasswordEncoder implements LegacyPasswordHasherInterface
$completedPassword = $this->getPasswordToHash($plainPassword, $salt);
foreach ($this->hashAlgoLegacy as $algo) {
if ('ssha' === $algo) {
return $this->compareSsha($hashedPassword, $completedPassword);
if ('ssha' === $algo && $this->compareSsha($hashedPassword, $completedPassword)) {
return true;
}
if ($this->isObsoleteAlgo($algo)) {
if (hash_equals(hash($algo, $completedPassword), $hashedPassword)) {