Piwik\Auth\
Main class to handle actions related to password strength rules and verification of those rules.
The class defines the following methods:
__construct()
getRules()
— Provides the rules for defining a strong password.validatePasswordStrength()
— Determines which rules a password candidate breaks with regards to password strength.formatValidationFailedMessage()
__construct()
$featureEnabled
(bool
) —getRules()
Provides the rules for defining a strong password. Rules are broken up into a regular expression which is applied to a password candidate, and a string which describes what the rule is testing for.
array
—
of rules to test password candidates against.validatePasswordStrength()
Determines which rules a password candidate breaks with regards to password strength.
It accepts the following parameter(s):
$candidate
(string
) —
The password candidate to be tested.Returns: array
—
of rules which the password breaks.
formatValidationFailedMessage()
It accepts the following parameter(s):
$brokenRules
(array
) —It returns a string
value.