|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
public interface PasswordHasher
This interface defines a hash function to be used to encrypt passwords.
It has two uses:
encryptPassword()
and store the returned value:
The hashed password and hash key pair are both required to properly check the password, a process which is done as follows:
Field Summary | |
---|---|
static java.lang.String |
CLASS_VERSION
|
Method Summary | |
---|---|
boolean |
checkPassword(java.lang.String pLoginPassword,
java.lang.String pEncryptedPassword,
java.lang.Object pHashKey)
Returns true if the login password matches the encrypted password. |
java.lang.String |
encryptPassword(java.lang.String pPassword)
Encrypts a password suitably for long-term storage. |
PasswordHasher |
getLoginPasswordHasher()
Returns a password hasher instance useful for performing a login. |
java.lang.Object |
getPasswordHashKey()
Returns the hash key (if any) that was used for hashing the password for login. |
java.lang.String |
hashPasswordForLogin(java.lang.String pPassword)
Performs the appropriate hashing function for a login process. |
Field Detail |
---|
static final java.lang.String CLASS_VERSION
Method Detail |
---|
java.lang.String encryptPassword(java.lang.String pPassword)
boolean checkPassword(java.lang.String pLoginPassword, java.lang.String pEncryptedPassword, java.lang.Object pHashKey)
java.lang.String hashPasswordForLogin(java.lang.String pPassword)
java.lang.Object getPasswordHashKey()
PasswordHasher getLoginPasswordHasher()
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |