com.mindbright.jca.security
Class SecureRandom
java.lang.Object
java.util.Random
com.mindbright.jca.security.SecureRandom
- All Implemented Interfaces:
- java.io.Serializable
- Direct Known Subclasses:
- SecureRandomAndPad
- public class SecureRandom
- extends java.util.Random
- See Also:
- Serialized Form
Methods inherited from class java.util.Random |
nextBoolean, nextDouble, nextFloat, nextGaussian, nextInt, nextInt, nextLong |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
SecureRandom
public SecureRandom()
SecureRandom
public SecureRandom(byte[] seed)
SecureRandom
protected SecureRandom(SecureRandomSpi secureRandomSpi,
Provider provider)
generateSeed
public byte[] generateSeed(int numBytes)
getInstance
public static SecureRandom getInstance(java.lang.String algorithm)
throws NoSuchAlgorithmException
- Throws:
NoSuchAlgorithmException
getInstance
public static SecureRandom getInstance(java.lang.String algorithm,
java.lang.String provider)
throws NoSuchAlgorithmException,
NoSuchProviderException
- Throws:
NoSuchAlgorithmException
NoSuchProviderException
getProvider
public Provider getProvider()
getSeed
public static byte[] getSeed(int numBytes)
next
protected final int next(int numBits)
nextBytes
public void nextBytes(byte[] bytes)
setSeed
public void setSeed(byte[] seed)
setSeed
public void setSeed(long seed)