public final class SecureRandom extends java.security.SecureRandomSpi implements java.io.Serializable, AlgorithmStatus
This class provides a cryptographically strong pseudo-random number generator based on the SHA1 message digest algorithm. Note that if a seed is not provided, we will generate a seed from a true random number generator(TRNG).
| Constructor and Description |
|---|
SecureRandom() |
SecureRandom(byte[] seed) |
| Modifier and Type | Method and Description |
|---|---|
byte[] |
engineGenerateSeed(int numBytes) |
void |
engineNextBytes(byte[] bytes) |
void |
engineSetSeed(byte[] seed) |
boolean |
isFipsApproved()
Module identifies if the cryptographic operation (algorithm) is FIPS certified
|
public boolean isFipsApproved()
AlgorithmStatusisFipsApproved in interface AlgorithmStatusAlgorithmStatus.isFipsApproved()public void engineSetSeed(byte[] seed)
engineSetSeed in class java.security.SecureRandomSpipublic void engineNextBytes(byte[] bytes)
engineNextBytes in class java.security.SecureRandomSpipublic byte[] engineGenerateSeed(int numBytes)
engineGenerateSeed in class java.security.SecureRandomSpi© Portions Copyright 2003, 2012 IBM Corporation. All rights reserved.
© Portions Copyright 2003, 2012, Oracle and/or its affiliates. All rights reserved.