public class SpringSecurityPasswordEncoder extends Object implements PasswordEncoder
PasswordEncoder from the Spring
Security Crypto package.
Add the spring-security-crypto dependency to use this class.| Constructor and Description |
|---|
SpringSecurityPasswordEncoder(org.springframework.security.crypto.password.PasswordEncoder delegate) |
| Modifier and Type | Method and Description |
|---|---|
String |
encode(String password)
Encode a password.
|
org.springframework.security.crypto.password.PasswordEncoder |
getDelegate() |
boolean |
matches(String plainPassword,
String encodedPassword)
Validate if a plainPassword matches
|
public SpringSecurityPasswordEncoder(org.springframework.security.crypto.password.PasswordEncoder delegate)
public String encode(String password)
PasswordEncoderencode in interface PasswordEncoderpassword - the not encoded passwordpublic boolean matches(String plainPassword, String encodedPassword)
PasswordEncodermatches in interface PasswordEncoderplainPassword - the not encoded password to checkencodedPassword - the encoded passwordtrue if they matchpublic org.springframework.security.crypto.password.PasswordEncoder getDelegate()
Copyright © 2017. All Rights Reserved.