Top Fields Constructors Methods
org.bouncycastle.crypto.general

pack-priv Class ContinuousTestingPseudoRNG

extends Object
implements DRBG
Class Inheritance
All Implemented Interfaces
org.bouncycastle.crypto.general.DRBG
Imports
org.bouncycastle.crypto.fips.FipsOperationError, .FipsStatus

Field Summary

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

Constructor Summary

AccessConstructor and Description
pack-priv
ContinuousTestingPseudoRNG(DRBG drbg, byte[] primaryAdditionalInput)

Method Summary

Modifier and TypeMethod and Description
private boolean
areEqual(byte[] a, byte[] b, int bOff)

public int
generate(byte[]
output array for generated bits.
output
,
byte[]
additional input to be added to the DRBG in this step.
additionalInput
,
boolean
true if a reseed should be forced, false otherwise.
predictionResistant
)

Implements org.bouncycastle.crypto.general.DRBG.generate.

Populate a passed in array with random data.
public int
getBlockSize()

Implements org.bouncycastle.crypto.general.DRBG.getBlockSize.

Return the block size of the DRBG.
private static int
getTestBlockSize(int output)

public void
reseed(byte[]
additional input to be added to the DRBG in this step.
additionalInput
)

Implements org.bouncycastle.crypto.general.DRBG.reseed.

Reseed the DRBG.
Inherited from java.lang.Object:
cloneequalsfinalizegetClasshashCodenotifynotifyAlltoStringwaitwaitwait

Field Detail

blockback to summary
private byte[] block
drbgback to summary
private final DRBG drbg
initialAdditionalInputback to summary
private byte[] initialAdditionalInput
MIN_RESOLUTIONback to summary
private static final int MIN_RESOLUTION
nextBlockback to summary
private byte[] nextBlock

Constructor Detail

ContinuousTestingPseudoRNGback to summary
pack-priv ContinuousTestingPseudoRNG(DRBG drbg, byte[] primaryAdditionalInput)

Method Detail

areEqualback to summary
private boolean areEqual(byte[] a, byte[] b, int bOff)
generateback to summary
public int generate(byte[] output, byte[] additionalInput, boolean predictionResistant)

Implements org.bouncycastle.crypto.general.DRBG.generate.

Doc from org.bouncycastle.crypto.general.DRBG.generate.

Populate a passed in array with random data.

Parameters
output:byte[]

output array for generated bits.

additionalInput:byte[]

additional input to be added to the DRBG in this step.

predictionResistant:boolean

true if a reseed should be forced, false otherwise.

Returns:int

number of bits generated, -1 if a reseed required.

getBlockSizeback to summary
public int getBlockSize()

Implements org.bouncycastle.crypto.general.DRBG.getBlockSize.

Doc from org.bouncycastle.crypto.general.DRBG.getBlockSize.

Return the block size of the DRBG.

Returns:int

the block size (in bits) produced by each round of the DRBG.

getTestBlockSizeback to summary
private static int getTestBlockSize(int output)
reseedback to summary
public void reseed(byte[] additionalInput)

Implements org.bouncycastle.crypto.general.DRBG.reseed.

Doc from org.bouncycastle.crypto.general.DRBG.reseed.

Reseed the DRBG.

Parameters
additionalInput:byte[]

additional input to be added to the DRBG in this step.