|
Bouncy Castle Cryptography Library 1.81 | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.bouncycastle.crypto.engines.SerpentEngineBase
org.bouncycastle.crypto.engines.TnepresEngine
Tnepres is a 128-bit 32-round block cipher with variable key lengths, including 128, 192 and 256 bit keys conjectured to be at least as secure as three-key triple-DES.
Tnepres is based on Serpent which was designed by Ross Anderson, Eli Biham and Lars Knudsen as a candidate algorithm for the NIST AES Quest. Unfortunately there was an endianness issue with test vectors in the AES submission and the resulting confusion lead to the Tnepres cipher as well, which is a byte swapped version of Serpent.
For full details see The Serpent home page
Field Summary |
Fields inherited from class org.bouncycastle.crypto.engines.SerpentEngineBase |
BLOCK_SIZE, encrypting, keyBits, wKey |
Constructor Summary | |
TnepresEngine()
|
Method Summary | |
protected void |
decryptBlock(byte[] input,
int inOff,
byte[] output,
int outOff)
Decrypt one block of ciphertext. |
protected void |
encryptBlock(byte[] input,
int inOff,
byte[] output,
int outOff)
Encrypt one block of plaintext. |
java.lang.String |
getAlgorithmName()
Return the name of the algorithm the cipher implements. |
protected int[] |
makeWorkingKey(byte[] key)
Expand a user-supplied key material into a session key. |
Methods inherited from class org.bouncycastle.crypto.engines.SerpentEngineBase |
getBlockSize, ib0, ib1, ib2, ib3, ib4, ib5, ib6, ib7, init, inverseLT, LT, processBlock, reset, rotateLeft, rotateRight, sb0, sb1, sb2, sb3, sb4, sb5, sb6, sb7 |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
public TnepresEngine()
Method Detail |
public java.lang.String getAlgorithmName()
BlockCipher
getAlgorithmName
in interface BlockCipher
getAlgorithmName
in class SerpentEngineBase
protected int[] makeWorkingKey(byte[] key) throws java.lang.IllegalArgumentException
makeWorkingKey
in class SerpentEngineBase
key
- The user-key bytes (multiples of 4) to use.
java.lang.IllegalArgumentException
protected void encryptBlock(byte[] input, int inOff, byte[] output, int outOff)
encryptBlock
in class SerpentEngineBase
input
- the array containing the input data.inOff
- offset into the in array the data starts at.output
- the array the output data will be copied into.outOff
- the offset into the out array the output will start at.protected void decryptBlock(byte[] input, int inOff, byte[] output, int outOff)
decryptBlock
in class SerpentEngineBase
input
- the array containing the input data.inOff
- offset into the in array the data starts at.output
- the array the output data will be copied into.outOff
- the offset into the out array the output will start at.
|
Bouncy Castle Cryptography Library 1.81 | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |