Package org.keycloak.models
Class PasswordPolicy
java.lang.Object
org.keycloak.models.PasswordPolicy
- All Implemented Interfaces:
Serializable
- Author:
- Stian Thorgersen
- See Also:
-
Nested Class Summary
-
Field Summary
-
Method Summary
Modifier and TypeMethodDescriptionstatic PasswordPolicy.Builder
build()
static PasswordPolicy
empty()
int
int
int
int
Policy to configure the maximum age of the authentication in seconds.int
<T> T
getPolicyConfig
(String key) int
static PasswordPolicy
parse
(KeycloakSession session, String policyString) toString()
-
Field Details
-
HASH_ALGORITHM_ID
- See Also:
-
HASH_ITERATIONS_ID
- See Also:
-
PASSWORD_HISTORY_ID
- See Also:
-
FORCE_EXPIRED_ID
- See Also:
-
RECOVERY_CODES_WARNING_THRESHOLD_DEFAULT
public static final int RECOVERY_CODES_WARNING_THRESHOLD_DEFAULT- See Also:
-
RECOVERY_CODES_WARNING_THRESHOLD_ID
- See Also:
-
MAX_AUTH_AGE_ID
- See Also:
-
PASSWORD_AGE
- See Also:
-
-
Method Details
-
empty
-
build
-
parse
-
getPolicies
-
getPolicyConfig
-
getHashAlgorithm
-
getHashIterations
public int getHashIterations() -
getExpiredPasswords
public int getExpiredPasswords() -
getPasswordAgeInDays
public int getPasswordAgeInDays() -
getDaysToExpirePassword
public int getDaysToExpirePassword() -
getRecoveryCodesWarningThreshold
public int getRecoveryCodesWarningThreshold() -
getMaxAuthAge
public int getMaxAuthAge()Policy to configure the maximum age of the authentication in seconds. If the user authentication is older than the given value, a reauthentication is enforced. Examples:maxAuthAge(0)
means the user has to reauthenticate immediately.maxAuthAge(60)
means the user has to reauthenticate if authentication is older than 60 seconds.
- Returns:
-
toString
-
toBuilder
-