Package org.jasypt.util.password
Interface PasswordEncryptor
- All Known Implementing Classes:
BasicPasswordEncryptor
,ConfigurablePasswordEncryptor
,RFC2307MD5PasswordEncryptor
,RFC2307SHAPasswordEncryptor
,RFC2307SMD5PasswordEncryptor
,RFC2307SSHAPasswordEncryptor
,StrongPasswordEncryptor
public interface PasswordEncryptor
Common interface for all util classes aimed at password encryption.
- Since:
- 1.2
- Author:
- Daniel Fernández
-
Method Summary
Modifier and TypeMethodDescriptionboolean
checkPassword
(String plainPassword, String encryptedPassword) Checks an unencrypted (plain) password against an encrypted one (a digest) to see if they match.encryptPassword
(String password) Encrypts (digests) a password.
-
Method Details
-
encryptPassword
Encrypts (digests) a password.- Parameters:
password
- the password to be encrypted.- Returns:
- the resulting digest.
-
checkPassword
Checks an unencrypted (plain) password against an encrypted one (a digest) to see if they match.- Parameters:
plainPassword
- the plain password to check.encryptedPassword
- the digest against which to check the password.- Returns:
- true if passwords match, false if not.
-