Module io.inverno.mod.security
Class PasswordPolicyException
java.lang.Object
java.lang.Throwable
java.lang.Exception
java.lang.RuntimeException
io.inverno.mod.security.SecurityException
io.inverno.mod.security.authentication.password.PasswordPolicyException
- All Implemented Interfaces:
Serializable
Thrown to indicate that a password does not comply with a password policy.
- Since:
- 1.5
- Author:
- Jeremy Kuhn
- See Also:
-
Constructor Summary
ConstructorDescriptionPasswordPolicyException
(PasswordPolicy.PasswordStrength passwordStrength) Creates a password policy exception with the specified strength.PasswordPolicyException
(PasswordPolicy.PasswordStrength passwordStrength, String message) Creates a password exception with the specified password strength and message.PasswordPolicyException
(PasswordPolicy.PasswordStrength passwordStrength, String message, Throwable cause) Creates a password exception with the specified password strength, message and cause.PasswordPolicyException
(PasswordPolicy.PasswordStrength passwordStrength, String message, Throwable cause, boolean enableSuppression, boolean writableStackTrace) Creates a password exception with the specified password strength, message, cause, suppression enabled or disabled and writable stack trace enabled or disabled.PasswordPolicyException
(PasswordPolicy.PasswordStrength passwordStrength, Throwable cause) Creates a password exception with the specified password strength and cause. -
Method Summary
Modifier and TypeMethodDescriptionReturns the strength of the non-compliant password.Methods inherited from class java.lang.Throwable
addSuppressed, fillInStackTrace, getCause, getLocalizedMessage, getMessage, getStackTrace, getSuppressed, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace, toString
-
Constructor Details
-
PasswordPolicyException
Creates a password policy exception with the specified strength.
- Parameters:
passwordStrength
- the password strength of the non-compliant password
-
PasswordPolicyException
Creates a password exception with the specified password strength and message.
- Parameters:
passwordStrength
- the password strength of the non-compliant passwordmessage
- the message
-
PasswordPolicyException
Creates a password exception with the specified password strength and cause.
- Parameters:
passwordStrength
- the password strength of the non-compliant passwordcause
- the cause
-
PasswordPolicyException
public PasswordPolicyException(PasswordPolicy.PasswordStrength passwordStrength, String message, Throwable cause) Creates a password exception with the specified password strength, message and cause.
- Parameters:
passwordStrength
- the password strength of the non-compliant passwordmessage
- the messagecause
- the cause
-
PasswordPolicyException
public PasswordPolicyException(PasswordPolicy.PasswordStrength passwordStrength, String message, Throwable cause, boolean enableSuppression, boolean writableStackTrace) Creates a password exception with the specified password strength, message, cause, suppression enabled or disabled and writable stack trace enabled or disabled.
- Parameters:
passwordStrength
- the password strength of the non-compliant passwordmessage
- the messagecause
- the causeenableSuppression
- true to enable suppression, false otherwisewritableStackTrace
- true to make the stack trace writable, false otherwise
-
-
Method Details
-
getPasswordStrength
Returns the strength of the non-compliant password.
- Returns:
- the password strength
-