public function isPasswordValid($password,
$hash) { if (!
str_contains($hash, self::DELIMITER
)) { throw new DomainException(sprintf('Invalid hash provided for the encoder %s.',
$this->
getName()));
} list
($iterations,
$salt) =
explode(self::DELIMITER,
$hash);
$verifyHash =
$this->
generateInternal($password,
$salt,
(int) $iterations);
return hash_equals($hash,
$verifyHash);
} /**
* @param string $password
*
* @return string
*/
public function encodePassword($password) {