public class OpenStegoCrypto
extends java.lang.Object
| Modifier and Type | Field and Description |
|---|---|
static java.lang.String |
ALGO_AES128
Constant for algorithm - AES128
|
static java.lang.String |
ALGO_AES256
Constant for algorithm - AES256
|
static java.lang.String |
ALGO_DES
Constant for algorithm - DES
|
| Constructor and Description |
|---|
OpenStegoCrypto(java.lang.String password,
java.lang.String algorithm)
Default constructor
|
| Modifier and Type | Method and Description |
|---|---|
byte[] |
decrypt(byte[] input)
Method to decrypt the data
|
byte[] |
encrypt(byte[] input)
Method to encrypt the data
|
public static final java.lang.String ALGO_DES
public static final java.lang.String ALGO_AES128
public static final java.lang.String ALGO_AES256
public OpenStegoCrypto(java.lang.String password,
java.lang.String algorithm)
throws OpenStegoException
password - Password to use for encryptionalgorithm - Cryptography algorithm to use. If null or blank value is provided, then it defaults to AES128OpenStegoExceptionpublic byte[] encrypt(byte[] input)
throws OpenStegoException
input - Data to be encryptedOpenStegoExceptionpublic byte[] decrypt(byte[] input)
throws OpenStegoException
input - Data to be decryptednull if password is invalid)OpenStegoExceptionCopyright © 2007-2021 Samir Vaidya. All Rights Reserved.