Class PasswordEntry
- java.lang.Object
-
- net.officefloor.web.security.store.PasswordEntry
-
- All Implemented Interfaces:
CredentialEntry
public class PasswordEntry extends java.lang.Object implements CredentialEntry
- Author:
- Daniel Sagenschneider
-
-
Constructor Summary
Constructors Constructor Description PasswordEntry(java.lang.String userId, byte[] credentials, java.util.Set<java.lang.String> roles)
Initiate.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description java.lang.String
getUserId()
Obtains the User Id.byte[]
retrieveCredentials()
Retrieves the credentials.java.util.Set<java.lang.String>
retrieveRoles()
Retrieves the roles.
-
-
-
Method Detail
-
getUserId
public java.lang.String getUserId()
Obtains the User Id.- Returns:
- User Id.
-
retrieveCredentials
public byte[] retrieveCredentials()
Description copied from interface:CredentialEntry
Retrieves the credentials.
The actual credentials are particular to the authentication scheme:
Basic
: clear text password (Charset
being US_ASCII)Digest
: encrypted "username:realm:password" as per the algorithm. For example, if the algorithm were MD5 then the following command would produce the appropriate value (Charset
being US_ASCII):echo -n "username:realm:password" | md5sum
Negotiate
: as necessary for authentication
- Specified by:
retrieveCredentials
in interfaceCredentialEntry
- Returns:
- Value as per above description.
-
retrieveRoles
public java.util.Set<java.lang.String> retrieveRoles()
Description copied from interface:CredentialEntry
Retrieves the roles.- Specified by:
retrieveRoles
in interfaceCredentialEntry
- Returns:
Set
of roles.
-
-