Enum Class PushCredentialsFile.PasswordType
java.lang.Object
java.lang.Enum<PushCredentialsFile.PasswordType>
com.iizix.server.push.engine.http.PushCredentialsFile.PasswordType
- All Implemented Interfaces:
Serializable, Comparable<PushCredentialsFile.PasswordType>, Constable
- Enclosing class:
PushCredentialsFile
The password storage types of section 3.2.
- Author:
- Christopher Mindus
Nested Class Summary
Nested classes/interfaces inherited from class Enum
Enum.EnumDesc<E>Enum Constant Summary
Enum ConstantsMethod Summary
Modifier and TypeMethodDescriptionbooleanisWeak()Tells whether the type is weak, i.e.Parses a type name, case-insensitively.Returns the enum constant of this class with the specified name.static PushCredentialsFile.PasswordType[]values()Returns an array containing the constants of this enum class, in the order they are declared.
Enum Constant Details
IZ1
IZ1:iterations:salt:hash, the server's own PBKDF2-HMAC-SHA256 storage, salted and bound to the user ID. Recommended.SHA512
128 hexadecimal digits: SHA-512 of the UTF-8 password, unsalted. Weak.SHA256
64 hexadecimal digits: SHA-256 of the UTF-8 password, unsalted. Weak, the floor.PLAIN
The password itself. Weak.
Method Details
values
Returns an array containing the constants of this enum class, in the order they are declared.- Returns:
- an array containing the constants of this enum class, in the order they are declared
valueOf
Returns the enum constant of this class with the specified name. The string must match exactly an identifier used to declare an enum constant in this class. (Extraneous whitespace characters are not permitted.)- Parameters:
name- the name of the enum constant to be returned.- Returns:
- the enum constant with the specified name
- Throws:
IllegalArgumentException- if this enum class has no constant with the specified nameNullPointerException- if the argument is null
parse
Parses a type name, case-insensitively.- Parameters:
name- The name, e.g.sha256.- Returns:
- The type, or null when the name is none of the four.
isWeak
public boolean isWeak()Tells whether the type is weak, i.e. counted in the section 3.4 WARNING: every type butIZ1.- Returns:
- true for a weak type.