public function PasswordInterface::check

Check whether a plain text password matches a stored hashed password.

Alternative implementations of this function may use other data in the $account object, for example the uid to look up the hash in a custom table or remote database.

Parameters

string $password: A plain-text password

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

Return value

bolean. TRUE or FALSE.

1 method overrides PasswordInterface::check()
PhpassHashedPassword::check in drupal/core/lib/Drupal/Core/Password/PhpassHashedPassword.php
Implements Drupal\Core\Password\PasswordInterface::checkPassword().

File

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

Class

PasswordInterface
Secure password hashing functions for user authentication.

Namespace

Drupal\Core\Password

Code

public function check($password, $account);