public function PasswordConstraintInterface::validate in Password Policy 8.3
Returns a true/false status if the password meets the constraint.
Parameters
string $password: The password entered by the end user.
\Drupal\user\UserInterface: The user which password is changed.
Return value
PasswordPolicyValidation Whether or not the password meets the constraint in the plugin.
6 methods override PasswordConstraintInterface::validate()
- CharacterTypes::validate in password_policy_character_types/
src/ Plugin/ PasswordConstraint/ CharacterTypes.php - Returns a true/false status if the password meets the constraint.
- ConsecutiveCharacters::validate in password_policy_consecutive/
src/ Plugin/ PasswordConstraint/ ConsecutiveCharacters.php - Returns a true/false status if the password meets the constraint.
- PasswordCharacter::validate in password_policy_characters/
src/ Plugin/ PasswordConstraint/ PasswordCharacter.php - Returns a true/false status if the password meets the constraint.
- PasswordHistory::validate in password_policy_history/
src/ Plugin/ PasswordConstraint/ PasswordHistory.php - Returns a true/false status if the password meets the constraint.
- PasswordLength::validate in password_policy_length/
src/ Plugin/ PasswordConstraint/ PasswordLength.php - Returns a true/false status if the password meets the constraint.
File
- src/
PasswordConstraintInterface.php, line 26
Class
- PasswordConstraintInterface
- An interface to define the expected operations of a password constraint.
Namespace
Drupal\password_policyCode
public function validate($password, UserInterface $user);