| Modifier and Type | Class and Description |
|---|---|
| private static class | |
| private static class | |
| private static class |
| Modifier and Type | Field and Description |
|---|---|
| private int | |
| private final EntropySourceProvider | |
| private byte[] | |
| private final SecureRandom | |
| private int |
| Access | Constructor and Description |
|---|---|
| public | SP800SecureRandomBuilder()
Basic constructor, creates a builder using an EntropySourceProvider based on the default SecureRandom with predictionResistant set to false. |
| public | SP800SecureRandomBuilder(SecureRandom
the SecureRandom acting as a source of entropy for DRBGs made by this builder. entropySource, boolean true if the SecureRandom seeder can be regarded as predictionResistant. predictionResistant)Construct a builder with an EntropySourceProvider based on the passed in SecureRandom and the passed in value for prediction resistance. |
| public | SP800SecureRandomBuilder(EntropySourceProvider
a provider of EntropySource objects. entropySourceProvider)Create a builder which makes creates the SecureRandom objects from a specified entropy source provider. |
| Modifier and Type | Method and Description |
|---|---|
| public SP800SecureRandom | Returns: a SecureRandom supported by a CTR DRBG.the block cipher to base the DRBG on. cipher, int key size in bits to be used with the block cipher. keySizeInBits, byte[] nonce value to use in DRBG construction. nonce, boolean specify whether the underlying DRBG in the resulting SecureRandom should reseed on each request for bytes. predictionResistant)Build a SecureRandom based on a SP 800-90A CTR DRBG. |
| public SP800SecureRandom | Returns: a SecureRandom supported by a Hash DRBG.digest algorithm to use in the DRBG underneath the SecureRandom. digest, byte[] nonce value to use in DRBG construction. nonce, boolean specify whether the underlying DRBG in the resulting SecureRandom should reseed on each request for bytes. predictionResistant)Build a SecureRandom based on a SP 800-90A Hash DRBG. |
| public SP800SecureRandom | Returns: a SecureRandom supported by a HMAC DRBG.HMAC algorithm to use in the DRBG underneath the SecureRandom. hMac, byte[] nonce value to use in DRBG construction. nonce, boolean specify whether the underlying DRBG in the resulting SecureRandom should reseed on each request for bytes. predictionResistant)Build a SecureRandom based on a SP 800-90A HMAC DRBG. |
| private static String | |
| public SP800SecureRandomBuilder | Returns: the current builder.the number of bits of entropy to be requested from the entropy source on each seed/reseed. entropyBitsRequired)Set the amount of entropy bits required for seeding and reseeding DRBGs used in building SecureRandom objects. |
| public SP800SecureRandomBuilder | Returns: the current builder.the personalisation string for the underlying DRBG. personalizationString)Set the personalization string for DRBG SecureRandoms created by this builder |
| public SP800SecureRandomBuilder | Returns: the current builder.the security strength (in bits) securityStrength)Set the security strength required for DRBGs used in building SecureRandom objects. |
| entropyBitsRequired | back to summary |
|---|---|
| private int entropyBitsRequired | |
| entropySourceProvider | back to summary |
|---|---|
| private final EntropySourceProvider entropySourceProvider | |
| personalizationString | back to summary |
|---|---|
| private byte[] personalizationString | |
| random | back to summary |
|---|---|
| private final SecureRandom random | |
| securityStrength | back to summary |
|---|---|
| private int securityStrength | |
| SP800SecureRandomBuilder | back to summary |
|---|---|
| public SP800SecureRandomBuilder() Basic constructor, creates a builder using an EntropySourceProvider based on the default SecureRandom with predictionResistant set to false. Any SecureRandom created from a builder constructed like this will make use of input passed to SecureRandom.setSeed() if the default SecureRandom does for its generateSeed() call. | |
| SP800SecureRandomBuilder | back to summary |
|---|---|
| public SP800SecureRandomBuilder(SecureRandom entropySource, boolean predictionResistant) Construct a builder with an EntropySourceProvider based on the passed in SecureRandom and the passed in value for prediction resistance. Any SecureRandom created from a builder constructed like this will make use of input passed to SecureRandom.setSeed() if the passed in SecureRandom does for its generateSeed() call.
| |
| SP800SecureRandomBuilder | back to summary |
|---|---|
| public SP800SecureRandomBuilder(EntropySourceProvider entropySourceProvider) Create a builder which makes creates the SecureRandom objects from a specified entropy source provider. Note If this constructor is used any calls to setSeed() in the resulting SecureRandom will be ignored.
| |
| buildCTR | back to summary |
|---|---|
| public SP800SecureRandom buildCTR(BlockCipher cipher, int keySizeInBits, byte[] nonce, boolean predictionResistant) Build a SecureRandom based on a SP 800-90A CTR DRBG.
| |
| buildHash | back to summary |
|---|---|
| public SP800SecureRandom buildHash(Digest digest, byte[] nonce, boolean predictionResistant) Build a SecureRandom based on a SP 800-90A Hash DRBG.
| |
| buildHMAC | back to summary |
|---|---|
| public SP800SecureRandom buildHMAC(Mac hMac, byte[] nonce, boolean predictionResistant) Build a SecureRandom based on a SP 800-90A HMAC DRBG.
| |
| getSimplifiedName | back to summary |
|---|---|
| private static String getSimplifiedName(Digest digest) | |
| setEntropyBitsRequired | back to summary |
|---|---|
| public SP800SecureRandomBuilder setEntropyBitsRequired(int entropyBitsRequired) Set the amount of entropy bits required for seeding and reseeding DRBGs used in building SecureRandom objects.
| |
| setPersonalizationString | back to summary |
|---|---|
| public SP800SecureRandomBuilder setPersonalizationString(byte[] personalizationString) Set the personalization string for DRBG SecureRandoms created by this builder
| |
| setSecurityStrength | back to summary |
|---|---|
| public SP800SecureRandomBuilder setSecurityStrength(int securityStrength) Set the security strength required for DRBGs used in building SecureRandom objects.
| |
| Modifier and Type | Field and Description |
|---|---|
| private final BlockCipher | |
| private final int | |
| private final byte[] | |
| private final byte[] | |
| private final int |
| Access | Constructor and Description |
|---|---|
| public | CTRDRBGProvider(BlockCipher blockCipher, int keySizeInBits, byte[] nonce, byte[] personalizationString, int securityStrength)
|
| Modifier and Type | Method and Description |
|---|---|
| public SP80090DRBG | |
| public String |
| blockCipher | back to summary |
|---|---|
| private final BlockCipher blockCipher | |
| keySizeInBits | back to summary |
|---|---|
| private final int keySizeInBits | |
| nonce | back to summary |
|---|---|
| private final byte[] nonce | |
| personalizationString | back to summary |
|---|---|
| private final byte[] personalizationString | |
| securityStrength | back to summary |
|---|---|
| private final int securityStrength | |
| CTRDRBGProvider | back to summary |
|---|---|
| public CTRDRBGProvider(BlockCipher blockCipher, int keySizeInBits, byte[] nonce, byte[] personalizationString, int securityStrength) | |
| get | back to summary |
|---|---|
| public SP80090DRBG get(EntropySource entropySource) Implements org. | |
| getAlgorithm | back to summary |
|---|---|
| public String getAlgorithm() Implements org. | |
| Modifier and Type | Field and Description |
|---|---|
| private final Digest | |
| private final byte[] | |
| private final byte[] | |
| private final int |
| Access | Constructor and Description |
|---|---|
| public |
| Modifier and Type | Method and Description |
|---|---|
| public SP80090DRBG | |
| public String |
| digest | back to summary |
|---|---|
| private final Digest digest | |
| nonce | back to summary |
|---|---|
| private final byte[] nonce | |
| personalizationString | back to summary |
|---|---|
| private final byte[] personalizationString | |
| securityStrength | back to summary |
|---|---|
| private final int securityStrength | |
| HashDRBGProvider | back to summary |
|---|---|
| public HashDRBGProvider(Digest digest, byte[] nonce, byte[] personalizationString, int securityStrength) | |
| get | back to summary |
|---|---|
| public SP80090DRBG get(EntropySource entropySource) Implements org. | |
| getAlgorithm | back to summary |
|---|---|
| public String getAlgorithm() Implements org. | |
| Modifier and Type | Field and Description |
|---|---|
| private final Mac | |
| private final byte[] | |
| private final byte[] | |
| private final int |
| Access | Constructor and Description |
|---|---|
| public |
| Modifier and Type | Method and Description |
|---|---|
| public SP80090DRBG | |
| public String |
| hMac | back to summary |
|---|---|
| private final Mac hMac | |
| nonce | back to summary |
|---|---|
| private final byte[] nonce | |
| personalizationString | back to summary |
|---|---|
| private final byte[] personalizationString | |
| securityStrength | back to summary |
|---|---|
| private final int securityStrength | |
| HMacDRBGProvider | back to summary |
|---|---|
| public HMacDRBGProvider(Mac hMac, byte[] nonce, byte[] personalizationString, int securityStrength) | |
| get | back to summary |
|---|---|
| public SP80090DRBG get(EntropySource entropySource) Implements org. | |
| getAlgorithm | back to summary |
|---|---|
| public String getAlgorithm() Implements org. | |