Class KeyWrapAlgorithm
- java.lang.Object
-
- com.microsoft.azure.keyvault.cryptography.Algorithm
-
- com.microsoft.azure.keyvault.cryptography.KeyWrapAlgorithm
-
-
Constructor Summary
Constructors Modifier Constructor Description protectedKeyWrapAlgorithm(String name)Constructor.
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description abstract ICryptoTransformCreateDecryptor(byte[] key)Creates aICryptoTransformimplementation for decryption.abstract ICryptoTransformCreateDecryptor(byte[] key, byte[] iv)Creates aICryptoTransformimplementation for decryption using the supplied initialization vector.abstract ICryptoTransformCreateDecryptor(byte[] key, byte[] iv, Provider provider)Creates aICryptoTransformimplementation for decryption using the supplied initialization vector and the specific provider for the Java Security API.abstract ICryptoTransformCreateDecryptor(byte[] key, Provider provider)Creates aICryptoTransformimplementation for decryption that uses the specified provider for the Java Security API.abstract ICryptoTransformCreateEncryptor(byte[] key)Creates aICryptoTransformimplementation for encryption.abstract ICryptoTransformCreateEncryptor(byte[] key, byte[] iv)Creates aICryptoTransformimplementation for encryption using the supplied initialization vector.abstract ICryptoTransformCreateEncryptor(byte[] key, byte[] iv, Provider provider)Creates aICryptoTransformimplementation for encryption using the supplied initialization vector and the specific provider for the Java Security API.abstract ICryptoTransformCreateEncryptor(byte[] key, Provider provider)Creates aICryptoTransformimplementation for encryption that uses the specified provider for the Java Security API.
-
-
-
Constructor Detail
-
KeyWrapAlgorithm
protected KeyWrapAlgorithm(String name)
Constructor.- Parameters:
name- The name of the algorithm.
-
-
Method Detail
-
CreateEncryptor
public abstract ICryptoTransform CreateEncryptor(byte[] key) throws NoSuchAlgorithmException, NoSuchPaddingException, InvalidKeyException, InvalidAlgorithmParameterException
Creates aICryptoTransformimplementation for encryption. Uses the default AES-KW initialization vector.- Parameters:
key- The AES key material to be used.- Returns:
- A
ICryptoTransformimplementation - Throws:
NoSuchAlgorithmExceptionNoSuchPaddingExceptionInvalidKeyExceptionInvalidAlgorithmParameterException
-
CreateEncryptor
public abstract ICryptoTransform CreateEncryptor(byte[] key, Provider provider) throws NoSuchAlgorithmException, NoSuchPaddingException, InvalidKeyException, InvalidAlgorithmParameterException
Creates aICryptoTransformimplementation for encryption that uses the specified provider for the Java Security API. Uses the default AES-KW initialization vector.- Parameters:
key- The AES key material to be used.provider- The provider to use.- Returns:
- A
ICryptoTransformimplementation - Throws:
NoSuchAlgorithmExceptionNoSuchPaddingExceptionInvalidKeyExceptionInvalidAlgorithmParameterException
-
CreateEncryptor
public abstract ICryptoTransform CreateEncryptor(byte[] key, byte[] iv) throws NoSuchAlgorithmException, NoSuchPaddingException, InvalidKeyException, InvalidAlgorithmParameterException
Creates aICryptoTransformimplementation for encryption using the supplied initialization vector.- Parameters:
key- The AES key material to be used.iv- The initialization vector to be used.- Returns:
- A
ICryptoTransformimplementation - Throws:
NoSuchAlgorithmExceptionNoSuchPaddingExceptionInvalidKeyExceptionInvalidAlgorithmParameterException
-
CreateEncryptor
public abstract ICryptoTransform CreateEncryptor(byte[] key, byte[] iv, Provider provider) throws NoSuchAlgorithmException, NoSuchPaddingException, InvalidKeyException, InvalidAlgorithmParameterException
Creates aICryptoTransformimplementation for encryption using the supplied initialization vector and the specific provider for the Java Security API.- Parameters:
key- The AES key material to be used.iv- The initialization vector to be used.provider- The provider to use.- Returns:
- A
ICryptoTransformimplementation - Throws:
NoSuchAlgorithmExceptionNoSuchPaddingExceptionInvalidKeyExceptionInvalidAlgorithmParameterException
-
CreateDecryptor
public abstract ICryptoTransform CreateDecryptor(byte[] key) throws NoSuchAlgorithmException, NoSuchPaddingException, InvalidKeyException, InvalidAlgorithmParameterException
Creates aICryptoTransformimplementation for decryption. Uses the default AES-KW initialization vector.- Parameters:
key- The AES key material to be used.- Returns:
- A
ICryptoTransformimplementation - Throws:
NoSuchAlgorithmExceptionNoSuchPaddingExceptionInvalidKeyExceptionInvalidAlgorithmParameterException
-
CreateDecryptor
public abstract ICryptoTransform CreateDecryptor(byte[] key, Provider provider) throws NoSuchAlgorithmException, NoSuchPaddingException, InvalidKeyException, InvalidAlgorithmParameterException
Creates aICryptoTransformimplementation for decryption that uses the specified provider for the Java Security API. Uses the default AES-KW initialization vector.- Parameters:
key- The AES key material to be used.provider- The provider to use.- Returns:
- A
ICryptoTransformimplementation - Throws:
NoSuchAlgorithmExceptionNoSuchPaddingExceptionInvalidKeyExceptionInvalidAlgorithmParameterException
-
CreateDecryptor
public abstract ICryptoTransform CreateDecryptor(byte[] key, byte[] iv) throws NoSuchAlgorithmException, NoSuchPaddingException, InvalidKeyException, InvalidAlgorithmParameterException
Creates aICryptoTransformimplementation for decryption using the supplied initialization vector.- Parameters:
key- The AES key material to be used.iv- The initialization vector to be used.- Returns:
- A
ICryptoTransformimplementation - Throws:
NoSuchAlgorithmExceptionNoSuchPaddingExceptionInvalidKeyExceptionInvalidAlgorithmParameterException
-
CreateDecryptor
public abstract ICryptoTransform CreateDecryptor(byte[] key, byte[] iv, Provider provider) throws NoSuchAlgorithmException, NoSuchPaddingException, InvalidKeyException, InvalidAlgorithmParameterException
Creates aICryptoTransformimplementation for decryption using the supplied initialization vector and the specific provider for the Java Security API.- Parameters:
key- The AES key material to be used.iv- The initialization vector to be used.provider- The provider to use.- Returns:
- A
ICryptoTransformimplementation - Throws:
NoSuchAlgorithmExceptionNoSuchPaddingExceptionInvalidKeyExceptionInvalidAlgorithmParameterException
-
-