Class PasswordValidatorProperties
java.lang.Object
com.broadleafcommerce.auth.user.validation.autoconfigure.PasswordValidatorProperties
@ConfigurationProperties("broadleaf.auth.password.validation")
public class PasswordValidatorProperties
extends Object
Any of the validations that use regex may be "disabled" by changing the regex to match anything:
^.*$ or nothing: ^$ (e.g., for whitespace or repeated characters)
- Author:
- Phillip Verheyden (phillipuniverse)
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected booleanbooleanExtension point for activating additional patterns that must conformPassword must include at least 1 number (e.g., 1, 2, 3)Password must be less than 255 charactersPassword must include at least 1 lowercase character (e.g., a, b, c)intDetermines the number of previous passwords to the system should remember.Password cannot contain any 3 sequentially repeated characters (e.g., 111, aaa, ---)Password must be at least 8 charactersPassword must include at least 1 special character (e.g., !, $, &)Password must include at least 1 uppercase character (e.g., A, B, C)Password cannot contain any whitespace charactersinthashCode()voidsetCustomPattern(String customPattern) Extension point for activating additional patterns that must conformvoidsetDigitPattern(String digitPattern) Password must include at least 1 number (e.g., 1, 2, 3)voidsetLongPattern(String longPattern) Password must be less than 255 charactersvoidsetLowerPattern(String lowerPattern) Password must include at least 1 lowercase character (e.g., a, b, c)voidsetPreviousPasswordsToRemember(int previousPasswordsToRemember) Determines the number of previous passwords to the system should remember.voidsetRepeatedPattern(String repeatedPattern) Password cannot contain any 3 sequentially repeated characters (e.g., 111, aaa, ---)voidsetShortPattern(String shortPattern) Password must be at least 8 charactersvoidsetSpecialPattern(String specialPattern) Password must include at least 1 special character (e.g., !, $, &)voidsetUpperPattern(String upperPattern) Password must include at least 1 uppercase character (e.g., A, B, C)voidsetWhitespacePattern(String whitespacePattern) Password cannot contain any whitespace characterstoString()
-
Constructor Details
-
PasswordValidatorProperties
public PasswordValidatorProperties()
-
-
Method Details
-
getShortPattern
Password must be at least 8 characters -
getLongPattern
Password must be less than 255 characters -
getUpperPattern
Password must include at least 1 uppercase character (e.g., A, B, C) -
getLowerPattern
Password must include at least 1 lowercase character (e.g., a, b, c) -
getDigitPattern
Password must include at least 1 number (e.g., 1, 2, 3) -
getSpecialPattern
Password must include at least 1 special character (e.g., !, $, &) -
getWhitespacePattern
Password cannot contain any whitespace characters -
getRepeatedPattern
Password cannot contain any 3 sequentially repeated characters (e.g., 111, aaa, ---) -
getCustomPattern
Extension point for activating additional patterns that must conform -
getPreviousPasswordsToRemember
public int getPreviousPasswordsToRemember()Determines the number of previous passwords to the system should remember. This is used to prevent a user from reusing a recently used password. Zero indicates no passwords are remembered. -
setShortPattern
Password must be at least 8 characters -
setLongPattern
Password must be less than 255 characters -
setUpperPattern
Password must include at least 1 uppercase character (e.g., A, B, C) -
setLowerPattern
Password must include at least 1 lowercase character (e.g., a, b, c) -
setDigitPattern
Password must include at least 1 number (e.g., 1, 2, 3) -
setSpecialPattern
Password must include at least 1 special character (e.g., !, $, &) -
setWhitespacePattern
Password cannot contain any whitespace characters -
setRepeatedPattern
Password cannot contain any 3 sequentially repeated characters (e.g., 111, aaa, ---) -
setCustomPattern
Extension point for activating additional patterns that must conform -
setPreviousPasswordsToRemember
public void setPreviousPasswordsToRemember(int previousPasswordsToRemember) Determines the number of previous passwords to the system should remember. This is used to prevent a user from reusing a recently used password. Zero indicates no passwords are remembered. -
equals
-
canEqual
-
hashCode
public int hashCode() -
toString
-