password_needs_rehash

Supported Versions: PHP 5 >= 5.5.0, PHP 7, PHP 8
Checks if the given hash matches the given options
<?php password_needs_rehash(string $hash, string|int|null $algo, array $options = []): bool
<?php     public function needsRehash($hashedValue, array $options = [])

    {

        return password_needs_rehash($hashedValue, $this->algorithm(), [

            'memory_cost' => $this->memory($options),

            'time_cost' => $this->time($options),

            'threads' => $this->threads($options),

        ]);

    }
<?php     public function needsRehash($hashedValue, array $options = [])

    {

        return password_needs_rehash($hashedValue, PASSWORD_BCRYPT, [

            'cost' => $this->cost($options),

        ]);

    }