Class NotSecurePseudoRandomSpi

java.lang.Object
java.security.SecureRandomSpi
org.apache.solr.util.NotSecurePseudoRandomSpi
All Implemented Interfaces:
Serializable

public class NotSecurePseudoRandomSpi extends SecureRandomSpi
A mocked up instance of SecureRandom that just uses Random under the covers. This is to prevent blocking issues that arise in platform default SecureRandom instances due to too many instances / not enough random entropy. Tests do not need secure SSL.
See Also:
  • Constructor Details

    • NotSecurePseudoRandomSpi

      public NotSecurePseudoRandomSpi()
  • Method Details

    • engineSetSeed

      protected void engineSetSeed(byte[] seed)
      Specified by:
      engineSetSeed in class SecureRandomSpi
    • engineNextBytes

      protected void engineNextBytes(byte[] bytes)
      Specified by:
      engineNextBytes in class SecureRandomSpi
    • engineGenerateSeed

      protected byte[] engineGenerateSeed(int numBytes)
      Specified by:
      engineGenerateSeed in class SecureRandomSpi
    • generateSeed

      public byte[] generateSeed(int numBytes)
      returns a new byte[] filled with static data
    • nextBytes

      public void nextBytes(byte[] bytes)
      fills the byte[] with static data
    • nextBytes

      public void nextBytes(byte[] bytes, SecureRandomParameters params)
    • setSeed

      public void setSeed(byte[] seed)
      NOOP
    • setSeed

      public void setSeed(long seed)
      NOOP
    • reseed

      public void reseed()
    • reseed

      public void reseed(SecureRandomParameters params)