password_needs_rehash

Determine if the password hash needs to be rehashed according to the options provided

If the answer is true, after validating the password using password_verify, rehash it.

Parameters
string $hash

The hash to test

#
int $algo

The algorithm used for new password hashes

#
array $options = []

The options array passed to password_hash

#
Returns
boolean

True if the password needs to be rehashed.