public class DES extends Object implements BlockCipher
| Constructor and Description |
|---|
DES()
standard constructor.
|
| Modifier and Type | Method and Description |
|---|---|
protected void |
desFunc(int[] wKey,
byte[] in,
int inOff,
byte[] out,
int outOff)
the DES engine.
|
protected int[] |
generateWorkingKey(boolean encrypting,
byte[] key,
int off)
generate an integer based working key based on our secret key and what we
processing we are planning to do.
|
String |
getAlgorithmName() |
int |
getBlockSize() |
void |
init(boolean encrypting,
byte[] key)
initialise a DES cipher.
|
void |
reset() |
void |
transformBlock(byte[] in,
int inOff,
byte[] out,
int outOff) |
public void init(boolean encrypting,
byte[] key)
init in interface BlockCipherencrypting - whether or not we are for encryption.key - the parameters required to set up the cipher.IllegalArgumentException - if the params argument is inappropriate.public String getAlgorithmName()
public int getBlockSize()
getBlockSize in interface BlockCipherpublic void transformBlock(byte[] in,
int inOff,
byte[] out,
int outOff)
transformBlock in interface BlockCipherpublic void reset()
protected int[] generateWorkingKey(boolean encrypting,
byte[] key,
int off)
protected void desFunc(int[] wKey,
byte[] in,
int inOff,
byte[] out,
int outOff)
Copyright © 2014. All rights reserved.