Class SpringCompromisedPasswordCheck
java.lang.Object
com.irurueta.authserver.authorization.api.web.password.SpringCompromisedPasswordCheck
- All Implemented Interfaces:
CompromisedPasswordCheck
Adapter of the
CompromisedPasswordCheck port over Spring Security's CompromisedPasswordChecker
(in production, the Have I Been Pwned range API, which only receives a hash prefix of the password).-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate final org.springframework.security.authentication.password.CompromisedPasswordCheckerChecker that does the work. -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionbooleanisCompromised(String password) Checks a password against a list of leaked passwords.
-
Field Details
-
checker
private final org.springframework.security.authentication.password.CompromisedPasswordChecker checkerChecker that does the work.
-
-
Constructor Details
-
SpringCompromisedPasswordCheck
public SpringCompromisedPasswordCheck()
-
-
Method Details
-
isCompromised
Description copied from interface:CompromisedPasswordCheckChecks a password against a list of leaked passwords.- Specified by:
isCompromisedin interfaceCompromisedPasswordCheck- Parameters:
password- the clear-text password.- Returns:
truewhen the password is known to be compromised.
-