ParsePasswordChecks (open)
Syntax
LOADLIB "mod::wrd/lib/auth/passwordpolicy.whlib";
RECORD ARRAY FUNCTION ParsePasswordChecks(STRING checks, RECORD options)
Parameters
STRING checks
Password validation checks. Space-separated list of checks. Possible checks:
- hibp Check that the password isn't present in the "Have I Been Pwned" database
- minlength:(amount) Make sure that password has at least (amount) characters
- lowercase:(amount) Make sure that password has at least (amount) lowercase characters
- uppercase:(amount) Make sure that password has at least (amount) uppercase characters
- digits:(amount) Make sure that password has at least (amount) digits
- symbols:(amount) Make sure that password has at least (amount) symbols
RECORD options
Options
strict
Throw on errors, defaults to FALSE
Return value
RECORD ARRAY
Parsed list of checks
STRING check
Token of the check ("hibp", "minlength", "lowercase", "uppercase", "digits", "symbols", "maxage", "noreuse")
STRING duration
Duration string (for checks that have an duration).
INTEGER value
Amount (for checks that have an amount).