- All Implemented Interfaces:
Algorithm
,Serializable
,Comparable<CipherAlgorithm>
,Constable
The enum
CipherAlgorithm
that defines the names for the algorithm component in a
transformation when requesting an instance of Cipher object-
Nested Class Summary
Nested classes/interfaces inherited from class java.lang.Enum
Enum.EnumDesc<E extends Enum<E>>
-
Enum Constant Summary
Enum ConstantsEnum ConstantDescriptionThe enum constant for AES algorithm.The enum constant for AES algorithm.The enum constant for ARCFOUR algorithm.The Blowfish algorithm.The ChaCha20 algorithm.The ChaCha20-Poly1305 algorithm.The DES algorithm.The DESede algorithm.The DESedeWrap algorithm.The DESedeWrap algorithm.The RC2 algorithm.The RC4 algorithm.The RC5 algorithm.The enum constant for RSA algorithm.The enum constant 'UNKNOWN' if the cipher algorithm is unknown -
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final String
The string constant AES_WRAP_ALGORITHM_NAMEstatic final String
The string constant CHA_CHA_20_ALGORITHM_NAMEstatic final String
The string constant CHA_CHA_20_ALGORITHM_NAMEstatic final String
The string constant DES_EDE_WRAP_ALGORITHM_NAMEstatic final String
The string constant ECIES_ALGORITHM_NAMEstatic final String
The string constant RC2_ALGORITHM_NAMEstatic final String
The string constant RC4_ALGORITHM_NAMEstatic final String
The string constant RC5_ALGORITHM_NAMEFields inherited from interface io.github.astrapi69.crypt.api.algorithm.Algorithm
UNKNOWN_ALGORITHM_NAME
-
Method Summary
Modifier and TypeMethodDescriptionGets the algorithm for encryption or decryptionstatic CipherAlgorithm
Returns the enum constant of this class with the specified name.static CipherAlgorithm[]
values()
Returns an array containing the constants of this enum class, in the order they are declared.
-
Enum Constant Details
-
AES
The enum constant for AES algorithm. -
AESWrap
The enum constant for AES algorithm. -
ARCFOUR
The enum constant for ARCFOUR algorithm. -
Blowfish
The Blowfish algorithm. -
ChaCha20
The ChaCha20 algorithm. -
ChaCha20_Poly1305
The ChaCha20-Poly1305 algorithm. -
DES
The DES algorithm. -
DESede
The DESede algorithm. -
DESedeWrap
The DESedeWrap algorithm. -
ECIES
The DESedeWrap algorithm. -
RC2
The RC2 algorithm. -
RC4
The RC4 algorithm. -
RC5
The RC5 algorithm. -
RSA
The enum constant for RSA algorithm. -
UNKNOWN
The enum constant 'UNKNOWN' if the cipher algorithm is unknown
-
-
Field Details
-
AES_WRAP_ALGORITHM_NAME
The string constant AES_WRAP_ALGORITHM_NAME- See Also:
-
CHA_CHA_20_ALGORITHM_NAME
The string constant CHA_CHA_20_ALGORITHM_NAME- See Also:
-
CHA_CHA_20_POLY1305_ALGORITHM_NAME
The string constant CHA_CHA_20_ALGORITHM_NAME- See Also:
-
DES_EDE_WRAP_ALGORITHM_NAME
The string constant DES_EDE_WRAP_ALGORITHM_NAME- See Also:
-
ECIES_ALGORITHM_NAME
The string constant ECIES_ALGORITHM_NAME- See Also:
-
RC2_ALGORITHM_NAME
The string constant RC2_ALGORITHM_NAME- See Also:
-
RC4_ALGORITHM_NAME
The string constant RC4_ALGORITHM_NAME- See Also:
-
RC5_ALGORITHM_NAME
The string constant RC5_ALGORITHM_NAME- See Also:
-
-
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
-
getAlgorithm
Gets the algorithm for encryption or decryption- Specified by:
getAlgorithm
in interfaceAlgorithm
- Returns:
- the algorithm
-