public function PasswordInterface::userNeedsNewHash

Check whether a user's hashed password needs to be replaced with a new hash.

This is typically called during the login process when the plain text password is available. A new hash is needed when the desired iteration count has changed by a modification of the password-service in the dependency injection container or if the user's password hash was generated in an update like user_update_7000() (see the Drupal 7 documentation).

Alternative implementations of this function might use other criteria based on the fields in $account.

Parameters

Drupal\user\User: A user object with at least the fields from the {users} table.

Return value

boolean TRUE or FALSE.

1 method overrides PasswordInterface::userNeedsNewHash()

File

drupal/core/lib/Drupal/Core/Password/PasswordInterface.php, line 62
Definition of Drupal\Core\Password\PasswordInterface

Class

PasswordInterface
Secure password hashing functions for user authentication.

Namespace

Drupal\Core\Password

Code

public function userNeedsNewHash($account);