public class XSalsa20Engine extends Salsa20Engine
XSalsa20 requires a 256 bit key, and a 192 bit nonce.
DEFAULT_ROUNDS, engineState, rounds, x
Constructor and Description |
---|
XSalsa20Engine() |
Modifier and Type | Method and Description |
---|---|
java.lang.String |
getAlgorithmName()
Return the name of the algorithm the cipher implements.
|
protected int |
getNonceSize() |
protected void |
setKey(byte[] keyBytes,
byte[] ivBytes)
XSalsa20 key generation: process 256 bit input key and 128 bits of the input nonce
using a core Salsa20 function without input addition to produce 256 bit working key
and use that with the remaining 64 bits of nonce to initialize a standard Salsa20 engine state.
|
advanceCounter, advanceCounter, generateKeyStream, getCounter, getPosition, init, packTauOrSigma, processBytes, reset, resetCounter, retreatCounter, retreatCounter, returnByte, salsaCore, seekTo, skip
public java.lang.String getAlgorithmName()
StreamCipher
getAlgorithmName
in interface StreamCipher
getAlgorithmName
in class Salsa20Engine
protected int getNonceSize()
getNonceSize
in class Salsa20Engine
protected void setKey(byte[] keyBytes, byte[] ivBytes)
setKey
in class Salsa20Engine