public class AESEncryption
extends java.lang.Object
| Constructor | Description |
|---|---|
AESEncryption(java.security.Key key) |
Creates a new AESEncryption instance.
|
| Modifier and Type | Method | Description |
|---|---|---|
int |
decrypt(byte[] input,
int inputOffset,
int inputLength,
byte[] output,
int outputOffset) |
|
int |
encrypt(byte[] input,
int inputOffset,
int inputLength,
byte[] output,
int outputOffset) |
|
int |
getDecryptOutputSize(int length) |
|
int |
getEncryptOutputSize(int length) |
public AESEncryption(java.security.Key key)
throws java.security.GeneralSecurityException
key - Key to use when encrypting/decrypting data.java.security.GeneralSecurityException - If a security error occurs.public int getDecryptOutputSize(int length)
public int getEncryptOutputSize(int length)
public int decrypt(byte[] input,
int inputOffset,
int inputLength,
byte[] output,
int outputOffset)
throws java.lang.Exception
java.lang.Exceptionpublic int encrypt(byte[] input,
int inputOffset,
int inputLength,
byte[] output,
int outputOffset)
throws java.lang.Exception
java.lang.Exception