Top Inners Fields Constructors Methods
org.bouncycastle.crypto.fips

pack-priv Class CSHAKEDigest

extends SHAKEDigest
Class Inheritance
Imports
org.bouncycastle.crypto.internal.Digest, .Xof, org.bouncycastle.crypto.internal.test.BasicKatTest, org.bouncycastle.util.Arrays, .Strings, org.bouncycastle.util.encoders.Hex

Nested and Inner Type Summary

Modifier and TypeClass and Description
private static class

Field Summary

Modifier and TypeField and Description
private final byte[]
private static final byte[]
private static final byte[]

Constructor Summary

AccessConstructor and Description
pack-priv
CSHAKEDigest(int bitLength, byte[] N, byte[] S)

Method Summary

Modifier and TypeMethod and Description
private void
public int
doOutput(byte[]
output array to write the output bytes to.
out
,
int
offset to start writing the bytes at.
outOff
,
int
the number of output bytes requested.
outLen
)

Overrides org.bouncycastle.crypto.fips.SHAKEDigest.doOutput.

Implements org.bouncycastle.crypto.internal.Xof.doOutput.

Start outputting the results of the final calculation for this digest.
private byte[]
encodeString(byte[] str)

private static byte[]
leftEncode(long strLen)

public void
reset()

Overrides org.bouncycastle.crypto.fips.KeccakDigest.reset.

Implements org.bouncycastle.crypto.internal.Digest.reset.

reset the digest back to it's initial state.
Inherited from org.bouncycastle.crypto.fips.SHAKEDigest:
doFinaldoFinaldoFinaldoFinalgetAlgorithmName

Field Detail

diffback to summary
private final byte[] diff
paddingback to summary
private static final byte[] padding
ZERO_BYTEback to summary
private static final byte[] ZERO_BYTE

Constructor Detail

CSHAKEDigestback to summary
pack-priv CSHAKEDigest(int bitLength, byte[] N, byte[] S)

Method Detail

diffPadAndAbsorbback to summary
private void diffPadAndAbsorb()
doOutputback to summary
public int doOutput(byte[] out, int outOff, int outLen)

Overrides org.bouncycastle.crypto.fips.SHAKEDigest.doOutput.

Implements org.bouncycastle.crypto.internal.Xof.doOutput.

Doc from org.bouncycastle.crypto.internal.Xof.doOutput.

Start outputting the results of the final calculation for this digest. Unlike doFinal, this method will continue producing output until the Xof is explicitly reset, or signals otherwise.

Parameters
out:byte[]

output array to write the output bytes to.

outOff:int

offset to start writing the bytes at.

outLen:int

the number of output bytes requested.

Returns:int

the number of bytes written

encodeStringback to summary
private byte[] encodeString(byte[] str)
leftEncodeback to summary
private static byte[] leftEncode(long strLen)
resetback to summary
public void reset()

Overrides org.bouncycastle.crypto.fips.KeccakDigest.reset.

Implements org.bouncycastle.crypto.internal.Digest.reset.

Doc from org.bouncycastle.crypto.internal.Digest.reset.

reset the digest back to it's initial state.

org.bouncycastle.crypto.fips back to summary

private Class CSHAKEDigest.KatTest<T extends Digest>

extends Object
implements BasicKatTest<T extends Digest>
Class Inheritance
All Implemented Interfaces
org.bouncycastle.crypto.internal.test.BasicKatTest

Field Summary

Modifier and TypeField and Description
private final byte[]
private static final byte[]

Constructor Summary

AccessConstructor and Description
pack-priv
KatTest(byte[] kat)

Method Summary

Modifier and TypeMethod and Description
public boolean
Inherited from java.lang.Object:
cloneequalsfinalizegetClasshashCodenotifynotifyAlltoStringwaitwaitwait

Field Detail

katback to summary
private final byte[] kat
stdShaVectorback to summary
private static final byte[] stdShaVector

Constructor Detail

KatTestback to summary
pack-priv KatTest(byte[] kat)

Method Detail

hasTestPassedback to summary
public boolean hasTestPassed(Digest digest)

Implements org.bouncycastle.crypto.internal.test.BasicKatTest.hasTestPassed.