| Modifier and Type | Class and Description |
|---|---|
| public static class | |
| public static class | |
| public static class | |
| public static class | |
| public static class | |
| public static class | |
| public static class | |
| public static class | |
| public static class | |
| public static class | |
| public static class | |
| public static class |
| Modifier and Type | Field and Description |
|---|---|
| private final FeedbackCipher | |
| private byte[] | |
| private int | |
| private final int | |
| private int | |
| private final Padding |
| Access | Constructor and Description |
|---|---|
| public | KeyWrapCipher(FeedbackCipher cipher, Padding padding, int keySize)
Creates an instance of KeyWrap cipher using the specified symmetric cipher whose block size must be 128-bit, and the supported mode and padding scheme. |
| Modifier and Type | Method and Description |
|---|---|
| private static byte[] | |
| protected byte[] | Returns: n/a.Implements abstract javax. See CipherSpi.engineDoFinal(...) |
| protected int | Returns: n/a.the input buffer. in, int inOfs, int the input length. inLen, byte[] the buffer for the result. out, int outOfs)Implements abstract javax. See CipherSpi.doFinal(...) |
| protected int | Returns: the block size (in bytes)Implements abstract javax. Returns the block size (in bytes). |
| protected byte[] | Returns: the user-specified iv, or null if the underlying algorithm does not use an IV, or if the IV has not yet been set.Implements abstract javax. Returns the initialization vector (IV) in a new buffer. |
| protected int | Returns: the "effective" key size of the given key object.the key object. key)Overrides javax. Returns the key size of the given key object in number of bits. |
| protected int | Returns: the required output buffer size (in bytes)the input length (in bytes) inLen)Implements abstract javax. Returns the length in bytes that an output buffer would need to be
given the input length |
| protected AlgorithmParameters | Returns: AlgorithmParameters object containing IV, or null if this cipher does not use any parameters.Implements abstract javax. Returns the parameters used with this cipher. |
| protected void | engineInit(int
the operation mode of this cipher. opmode, Key the secret key. key, SecureRandom the source of randomness. random)Implements abstract javax. Initializes this cipher with a key and a source of randomness. |
| protected void | engineInit(int
the operation mode of this cipher. opmode, Key the secret key. key, AlgorithmParameterSpec the algorithm parameters; if not null, must be of type
IvParameterSpec params, SecureRandom the source of randomness. random)Implements abstract javax. Initializes this cipher with a key, a set of algorithm parameters, and a source of randomness. |
| protected void | engineInit(int
the operation mode of this cipher. opmode, Key the secret key. key, AlgorithmParameters the algorithm parameters; if not null, must be able to
be converted to IvParameterSpec. params, SecureRandom the source of randomness. random)Implements abstract javax. Initializes this cipher with a key, a set of algorithm parameters, and a source of randomness. |
| protected void | engineSetMode(String
the cipher mode mode)Implements abstract javax. Sets the mode of this cipher. |
| protected void | engineSetPadding(String
the padding mechanism padding)Implements abstract javax. Sets the padding mechanism of this cipher. |
| protected Key | Returns: the unwrapped key.the key to be unwrapped. wrappedKey, String the algorithm the wrapped key is for. wrappedKeyAlgorithm, int the type of the wrapped key.
This is one of wrappedKeyType)Cipher.SECRET_KEY,
Cipher.PRIVATE_KEY, or Cipher.PUBLIC_KEY.Overrides javax. Unwrap a previously wrapped key. |
| protected byte[] | Returns: null.the input buffer. in, int the offset in inOffset, int in where the input
starts.the input length. inLen)Implements abstract javax. See CipherSpi.engineUpdate(...) - buffers data internally as only single part operation is supported. |
| protected int | Returns: n/a.the input buffer. in, int the offset in inOffset, int in where the input
starts.the input length. inLen, byte[] the buffer for the result. out, int the offset in outOffset)out where the result
is stored.Implements abstract javax. See CipherSpi.engineUpdate(...) - buffers data internally as only single part operation is supported. |
| protected byte[] | Returns: the wrapped key.the key to be wrapped. key)Overrides javax. Wrap a key. |
| private int | |
| private int | |
| private int | |
| private void | |
| private void | |
| private void |
| cipher | back to summary |
|---|---|
| private final FeedbackCipher cipher | |
| dataBuf | back to summary |
|---|---|
| private byte[] dataBuf | |
| dataIdx | back to summary |
|---|---|
| private int dataIdx | |
| fixedKeySize | back to summary |
|---|---|
| private final int fixedKeySize | |
| opmode | back to summary |
|---|---|
| private int opmode | |
| padding | back to summary |
|---|---|
| private final Padding padding | |
| KeyWrapCipher | back to summary |
|---|---|
| public KeyWrapCipher(FeedbackCipher cipher, Padding padding, int keySize) Creates an instance of KeyWrap cipher using the specified symmetric cipher whose block size must be 128-bit, and the supported mode and padding scheme. | |
| checkKey | back to summary |
|---|---|
| private static byte[] checkKey(Key key, int fixedKeySize) throws InvalidKeyException | |
| engineDoFinal | back to summary |
|---|---|
| protected byte[] engineDoFinal(byte[] in, int inOfs, int inLen) throws IllegalBlockSizeException, BadPaddingException Implements abstract javax. See CipherSpi.engineDoFinal(...)
| |
| engineDoFinal | back to summary |
|---|---|
| protected int engineDoFinal(byte[] in, int inOfs, int inLen, byte[] out, int outOfs) throws IllegalBlockSizeException, ShortBufferException, BadPaddingException Implements abstract javax. See CipherSpi.doFinal(...)
| |
| engineGetBlockSize | back to summary |
|---|---|
| protected int engineGetBlockSize() Implements abstract javax. Doc from javax. Returns the block size (in bytes).
| |
| engineGetIV | back to summary |
|---|---|
| protected byte[] engineGetIV() Implements abstract javax. Returns the initialization vector (IV) in a new buffer.
| |
| engineGetKeySize | back to summary |
|---|---|
| protected int engineGetKeySize(Key key) throws InvalidKeyException Overrides javax. Returns the key size of the given key object in number of bits.
| |
| engineGetOutputSize | back to summary |
|---|---|
| protected int engineGetOutputSize(int inLen) Implements abstract javax. Returns the length in bytes that an output buffer would need to be
given the input length The actual output length of the next
| |
| engineGetParameters | back to summary |
|---|---|
| protected AlgorithmParameters engineGetParameters() Implements abstract javax. Returns the parameters used with this cipher.
| |
| engineInit | back to summary |
|---|---|
| protected void engineInit(int opmode, Key key, SecureRandom random) throws InvalidKeyException Implements abstract javax. Initializes this cipher with a key and a source of randomness.
| |
| engineInit | back to summary |
|---|---|
| protected void engineInit(int opmode, Key key, AlgorithmParameterSpec params, SecureRandom random) throws InvalidKeyException, InvalidAlgorithmParameterException Implements abstract javax. Initializes this cipher with a key, a set of algorithm parameters, and a source of randomness.
| |
| engineInit | back to summary |
|---|---|
| protected void engineInit(int opmode, Key key, AlgorithmParameters params, SecureRandom random) throws InvalidKeyException, InvalidAlgorithmParameterException Implements abstract javax. Initializes this cipher with a key, a set of algorithm parameters, and a source of randomness.
| |
| engineSetMode | back to summary |
|---|---|
| protected void engineSetMode(String mode) throws NoSuchAlgorithmException Implements abstract javax. Sets the mode of this cipher. Must match the mode specified in the constructor.
| |
| engineSetPadding | back to summary |
|---|---|
| protected void engineSetPadding(String padding) throws NoSuchPaddingException Implements abstract javax. Sets the padding mechanism of this cipher. The specified padding scheme should match what this cipher is configured with.
| |
| engineUnwrap | back to summary |
|---|---|
| protected Key engineUnwrap(byte[] wrappedKey, String wrappedKeyAlgorithm, int wrappedKeyType) throws InvalidKeyException, NoSuchAlgorithmException Overrides javax. Unwrap a previously wrapped key.
| |
| engineUpdate | back to summary |
|---|---|
| protected byte[] engineUpdate(byte[] in, int inOffset, int inLen) Implements abstract javax. See CipherSpi.engineUpdate(...) - buffers data internally as only single part operation is supported.
| |
| engineUpdate | back to summary |
|---|---|
| protected int engineUpdate(byte[] in, int inOffset, int inLen, byte[] out, int outOffset) throws ShortBufferException Implements abstract javax. See CipherSpi.engineUpdate(...) - buffers data internally as only single part operation is supported.
| |
| engineWrap | back to summary |
|---|---|
| protected byte[] engineWrap(Key key) throws IllegalBlockSizeException, InvalidKeyException Overrides javax. Wrap a key.
| |
| helperDecrypt | back to summary |
|---|---|
| private int helperDecrypt(byte[] inBuf, int inLen) throws IllegalBlockSizeException, BadPaddingException, ShortBufferException | |
| helperEncrypt | back to summary |
|---|---|
| private int helperEncrypt(byte[] inBuf, int inLen) throws IllegalBlockSizeException, ShortBufferException | |
| implDoFinal | back to summary |
|---|---|
| private int implDoFinal(byte[] in, int inOfs, int inLen, byte[] out) throws IllegalBlockSizeException, BadPaddingException, ShortBufferException | |
| implInit | back to summary |
|---|---|
| private void implInit(int opmode, Key key, byte[] iv, SecureRandom random) throws InvalidKeyException, InvalidAlgorithmParameterException | |
| implUpdate | back to summary |
|---|---|
| private void implUpdate(byte[] in, int inOfs, int inLen) | |
| store | back to summary |
|---|---|
| private void store(byte[] in, int inOfs, int inLen) | |
| Access | Constructor and Description |
|---|---|
| public |
| AES128_KW_NoPadding | back to summary |
|---|---|
| public AES128_KW_NoPadding() | |
| Access | Constructor and Description |
|---|---|
| public |
| AES128_KW_PKCS5Padding | back to summary |
|---|---|
| public AES128_KW_PKCS5Padding() | |
| Access | Constructor and Description |
|---|---|
| public |
| AES128_KWP_NoPadding | back to summary |
|---|---|
| public AES128_KWP_NoPadding() | |
| Access | Constructor and Description |
|---|---|
| public |
| AES192_KW_NoPadding | back to summary |
|---|---|
| public AES192_KW_NoPadding() | |
| Access | Constructor and Description |
|---|---|
| public |
| AES192_KW_PKCS5Padding | back to summary |
|---|---|
| public AES192_KW_PKCS5Padding() | |
| Access | Constructor and Description |
|---|---|
| public |
| AES192_KWP_NoPadding | back to summary |
|---|---|
| public AES192_KWP_NoPadding() | |
| Access | Constructor and Description |
|---|---|
| public |
| AES256_KW_NoPadding | back to summary |
|---|---|
| public AES256_KW_NoPadding() | |
| Access | Constructor and Description |
|---|---|
| public |
| AES256_KW_PKCS5Padding | back to summary |
|---|---|
| public AES256_KW_PKCS5Padding() | |
| Access | Constructor and Description |
|---|---|
| public |
| AES256_KWP_NoPadding | back to summary |
|---|---|
| public AES256_KWP_NoPadding() | |
| Access | Constructor and Description |
|---|---|
| public |
| AES_KW_NoPadding | back to summary |
|---|---|
| public AES_KW_NoPadding() | |
| Access | Constructor and Description |
|---|---|
| public |
| AES_KW_PKCS5Padding | back to summary |
|---|---|
| public AES_KW_PKCS5Padding() | |
| Access | Constructor and Description |
|---|---|
| public |
| AES_KWP_NoPadding | back to summary |
|---|---|
| public AES_KWP_NoPadding() | |