Interface ClearPassword
- All Superinterfaces:
Cloneable, Destroyable, Key, Password, Serializable, TwoWayPassword
A simple clear-text password.
-
Field Summary
FieldsFields inherited from interface Key
serialVersionUID -
Method Summary
Modifier and TypeMethodDescriptionclone()Creates and returns a copy of thisPassword.static ClearPasswordCreate a raw implementation of this password type.char[]Get the password characters.Methods inherited from interface Destroyable
destroy, isDestroyedMethods inherited from interface Key
getAlgorithm, getEncoded, getFormatMethods inherited from interface Password
castAndApply, castAndApply, castAs, castAs, getParameterSpec, impliesParameters
-
Field Details
-
ALGORITHM_CLEAR
-
-
Method Details
-
getPassword
Get the password characters.- Returns:
- the password characters
- Throws:
IllegalStateException
-
clone
ClearPassword clone()Creates and returns a copy of thisPassword.- Specified by:
clonein interfacePassword- Specified by:
clonein interfaceTwoWayPassword- Returns:
- a copy of this
Password.
-
createRaw
Create a raw implementation of this password type. No validation of the content is performed, and the password must be "adopted" in to aPasswordFactory(via thePasswordFactory.translate(Password)method) before it can be validated and used to verify guesses.- Parameters:
algorithm- the algorithm namepassword- the password characters- Returns:
- the raw password implementation
-