public class IceCrypto extends Object
| Constructor and Description |
|---|
IceCrypto(int level)
Create a new ICE key with the specified level.
|
| Modifier and Type | Method and Description |
|---|---|
int |
blockSize()
Return the block size, in bytes.
|
void |
clear()
Clear the key schedule to prevent memory snooping.
|
static byte[] |
decrypt(byte[] in,
byte[] key)
Encrypt data using given key.
|
void |
decryptBlock(byte[] ciphertext,
byte[] plaintext)
Decrypt a block of 8 bytes of data.
|
static byte[] |
encrypt(byte[] in,
byte[] key)
Encrypt data using given key.
|
void |
encryptBlock(byte[] plaintext,
byte[] ciphertext)
Encrypt a block of 8 bytes of data.
|
int |
keySize()
Return the key size, in bytes.
|
void |
set(byte[] key)
Set the key schedule of an ICE key.
|
public IceCrypto(int level)
level - public void set(byte[] key)
key - public void clear()
public void encryptBlock(byte[] plaintext,
byte[] ciphertext)
public void decryptBlock(byte[] ciphertext,
byte[] plaintext)
public int keySize()
public int blockSize()
public static byte[] encrypt(byte[] in,
byte[] key)
in - clear text datakey - encryption keypublic static byte[] decrypt(byte[] in,
byte[] key)
in - encrypted datakey - encryption keyCopyright © 2018. All rights reserved.