Package org.conscrypt
Class OpenSSLEvpCipherAES
- java.lang.Object
-
- javax.crypto.CipherSpi
-
- org.conscrypt.OpenSSLCipher
-
- org.conscrypt.OpenSSLEvpCipher
-
- org.conscrypt.OpenSSLEvpCipherAES
-
- Direct Known Subclasses:
OpenSSLEvpCipherAES.AES
,OpenSSLEvpCipherAES.AES_128
,OpenSSLEvpCipherAES.AES_256
@Internal public abstract class OpenSSLEvpCipherAES extends OpenSSLEvpCipher
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static class
OpenSSLEvpCipherAES.AES
static class
OpenSSLEvpCipherAES.AES_128
static class
OpenSSLEvpCipherAES.AES_256
-
Nested classes/interfaces inherited from class org.conscrypt.OpenSSLCipher
OpenSSLCipher.Mode, OpenSSLCipher.Padding
-
-
Field Summary
Fields Modifier and Type Field Description private static int
AES_BLOCK_SIZE
-
Fields inherited from class org.conscrypt.OpenSSLCipher
encodedKey, iv, mode
-
-
Constructor Summary
Constructors Constructor Description OpenSSLEvpCipherAES(OpenSSLCipher.Mode mode, OpenSSLCipher.Padding padding)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description (package private) void
checkSupportedMode(OpenSSLCipher.Mode mode)
Checks whether the cipher supports this particular ciphermode
and throwsNoSuchAlgorithmException
if it doesn't.(package private) void
checkSupportedPadding(OpenSSLCipher.Padding padding)
Checks whether the cipher supports this particular cipherpadding
and throwsNoSuchPaddingException
if it doesn't.(package private) java.lang.String
getBaseCipherName()
Returns the standard name for the particular algorithm.(package private) int
getCipherBlockSize()
(package private) java.lang.String
getCipherName(int keyLength, OpenSSLCipher.Mode mode)
Returns the OpenSSL cipher name for the particularkeySize
and ciphermode
.-
Methods inherited from class org.conscrypt.OpenSSLEvpCipher
doFinalInternal, engineInitInternal, getOutputSizeForFinal, getOutputSizeForUpdate, updateInternal
-
Methods inherited from class org.conscrypt.OpenSSLCipher
checkSupportedKeySize, engineDoFinal, engineDoFinal, engineGetBlockSize, engineGetIV, engineGetKeySize, engineGetOutputSize, engineGetParameters, engineInit, engineInit, engineInit, engineSetMode, engineSetPadding, engineUnwrap, engineUpdate, engineUpdate, engineWrap, getPadding, getParameterSpec, isEncrypting, supportsVariableSizeIv, supportsVariableSizeKey
-
-
-
-
Field Detail
-
AES_BLOCK_SIZE
private static final int AES_BLOCK_SIZE
- See Also:
- Constant Field Values
-
-
Constructor Detail
-
OpenSSLEvpCipherAES
OpenSSLEvpCipherAES(OpenSSLCipher.Mode mode, OpenSSLCipher.Padding padding)
-
-
Method Detail
-
checkSupportedMode
void checkSupportedMode(OpenSSLCipher.Mode mode) throws java.security.NoSuchAlgorithmException
Description copied from class:OpenSSLCipher
Checks whether the cipher supports this particular ciphermode
and throwsNoSuchAlgorithmException
if it doesn't.- Specified by:
checkSupportedMode
in classOpenSSLCipher
- Throws:
java.security.NoSuchAlgorithmException
-
checkSupportedPadding
void checkSupportedPadding(OpenSSLCipher.Padding padding) throws javax.crypto.NoSuchPaddingException
Description copied from class:OpenSSLCipher
Checks whether the cipher supports this particular cipherpadding
and throwsNoSuchPaddingException
if it doesn't.- Specified by:
checkSupportedPadding
in classOpenSSLCipher
- Throws:
javax.crypto.NoSuchPaddingException
-
getBaseCipherName
java.lang.String getBaseCipherName()
Description copied from class:OpenSSLCipher
Returns the standard name for the particular algorithm.- Specified by:
getBaseCipherName
in classOpenSSLCipher
-
getCipherName
java.lang.String getCipherName(int keyLength, OpenSSLCipher.Mode mode)
Description copied from class:OpenSSLEvpCipher
Returns the OpenSSL cipher name for the particularkeySize
and ciphermode
.- Specified by:
getCipherName
in classOpenSSLEvpCipher
-
getCipherBlockSize
int getCipherBlockSize()
- Specified by:
getCipherBlockSize
in classOpenSSLCipher
-
-