correction phpstan
Cadoles/hydra-sql/pipeline/pr-develop This commit is unstable Details

This commit is contained in:
Matthieu Lamalle 2023-12-14 10:25:22 +01:00
parent 341a1ecd87
commit b5de7ee873
2 changed files with 4 additions and 7 deletions

View File

@ -23,7 +23,7 @@ DSN_REMOTE_DATABASE="pgsql:host='postgres';port=5432;dbname=lasql"
APP_LOCALES="fr,en" APP_LOCALES="fr,en"
HASH_ALGO_LEGACY="sha256, bcrypt" HASH_ALGO_LEGACY="sha256, bcrypt"
SECURITY_PATTERN="password,salt,pepper" SECURITY_PATTERN="password,salt,pepper"
REDIS_DSN="redis://redis:6379 REDIS_DSN="redis://redis:6379"
PEPPER= PEPPER=
``` ```
### Algorithmes de hashage compatibles ### Algorithmes de hashage compatibles

View File

@ -54,7 +54,7 @@ class PasswordEncoder implements LegacyPasswordHasherInterface
return true; return true;
} }
foreach(hash_algos() as $algo) { foreach (hash_algos() as $algo) {
if (hash_equals($hashedPassword, hash($algo, $completedPassword))) { if (hash_equals($hashedPassword, hash($algo, $completedPassword))) {
return true; return true;
} }
@ -76,9 +76,6 @@ class PasswordEncoder implements LegacyPasswordHasherInterface
/** /**
* Retourne la string à hasher en fonction du pattern indiqué * Retourne la string à hasher en fonction du pattern indiqué
* *
* @param mixed $plainTextPassword
* @param mixed $salt
*
* @return string * @return string
*/ */
protected function getPasswordToHash($plainTextPassword, $salt) protected function getPasswordToHash($plainTextPassword, $salt)