public class PasswordPolicy extends Object
Modifier and Type | Method and Description |
---|---|
boolean |
canChangePassword()
Checks if the password can be changed or not.
|
String |
check(String password)
Estimate password strength if it's OK, and if it is, null is
returned.
|
static PasswordPolicy |
createAdminPolicyWithAdvancedEntropyChecking()
Creates a password policy for administrators with its defaults, but with
the addition of advanced entropy checking.
|
static PasswordPolicy |
from(PolicyProps settings)
Creates the password policy based on pure defaults if the property container
is null, otherwise based on those settings.
|
static String |
generateStrongPassword()
Generates a new strong random password.
|
int |
getHistoryLength()
Gets the password history length.
|
boolean |
mustChangePassword()
Checks if the password must be changed at next login.
|
public static PasswordPolicy from(PolicyProps settings)
settings
- The settings property container, or null for defaults.public static PasswordPolicy createAdminPolicyWithAdvancedEntropyChecking()
public static String generateStrongPassword()
public String check(String password)
password
- The password to check.public int getHistoryLength()
public boolean canChangePassword()
public boolean mustChangePassword()
iizi® is a registered trademark of Mindus SARL. © Copyright 2019 Mindus SARL. All rights reserved.