@ThreadSafety(level=COMPLETELY_THREADSAFE) public enum PassphraseEncryptionCipherType extends java.lang.Enum<PassphraseEncryptionCipherType>
PassphraseEncryptedOutputStream
.Enum Constant and Description |
---|
AES_128
Cipher settings that use a 128-bit AES cipher.
|
AES_256
Cipher settings that use a 256-bit AES cipher.
|
Modifier and Type | Method and Description |
---|---|
static PassphraseEncryptionCipherType |
forName(java.lang.String name)
Retrieves the cipher type value for the provided name.
|
java.lang.String |
getCipherTransformation()
Retrieves the cipher transformation that will be used for the encryption.
|
int |
getInitializationVectorLengthBytes()
Retrieves the length (in bytes) to use for the initialization vector when
generating the cipher.
|
java.lang.String |
getKeyFactoryAlgorithm()
Retrieves the name of the algorithm that will be used to generate the
encryption key from the passphrase.
|
int |
getKeyFactoryIterationCount()
Retrieves the iteration count that will be used when generating the
encryption key from the passphrase.
|
int |
getKeyFactorySaltLengthBytes()
Retrieves the length (in bytes) to use for the salt when generating the
encryption key from the passphrase.
|
int |
getKeyLengthBits()
Retrieves the length (in bits) for the encryption key to generate.
|
java.lang.String |
getMacAlgorithm()
Retrieves the name of the algorithm that will be used to generate a MAC of
the encryption header contents.
|
static PassphraseEncryptionCipherType |
getStrongestAvailableCipherType()
Retrieves the cipher type value that corresponds to the strongest supported
level of protection that is available in the underlying JVM.
|
java.lang.String |
toString()
Retrieves a string representation of this cipher type value.
|
void |
toString(java.lang.StringBuilder buffer)
Appends a string representation of this cipher type value to the provided
buffer.
|
static PassphraseEncryptionCipherType |
valueOf(java.lang.String name)
Returns the enum constant of this type with the specified name.
|
static PassphraseEncryptionCipherType[] |
values()
Returns an array containing the constants of this enum type, in
the order they are declared.
|
public static final PassphraseEncryptionCipherType AES_128
public static final PassphraseEncryptionCipherType AES_256
public static PassphraseEncryptionCipherType[] values()
for (PassphraseEncryptionCipherType c : PassphraseEncryptionCipherType.values()) System.out.println(c);
public static PassphraseEncryptionCipherType valueOf(java.lang.String name)
name
- the name of the enum constant to be returned.java.lang.IllegalArgumentException
- if this enum type has no constant with the specified namejava.lang.NullPointerException
- if the argument is null@NotNull public java.lang.String getCipherTransformation()
public int getKeyLengthBits()
@NotNull public java.lang.String getKeyFactoryAlgorithm()
public int getKeyFactoryIterationCount()
public int getKeyFactorySaltLengthBytes()
public int getInitializationVectorLengthBytes()
@NotNull public java.lang.String getMacAlgorithm()
@Nullable public static PassphraseEncryptionCipherType forName(@NotNull java.lang.String name)
name
- The name of the cipher type value to retrieve.null
if the
provided name does not map to any cipher type value.@NotNull public static PassphraseEncryptionCipherType getStrongestAvailableCipherType()
@NotNull public java.lang.String toString()
toString
in class java.lang.Enum<PassphraseEncryptionCipherType>