Class SecureRandomProvider

java.lang.Object
net.schmizz.sshj.transport.random.SecureRandomProvider
All Implemented Interfaces:
Random
Direct Known Subclasses:
BouncyCastleFipsRandom, BouncyCastleRandom, JCERandom

public class SecureRandomProvider extends Object implements Random
  • Field Details

    • logger

      private static final org.slf4j.Logger logger
    • tmp

      private byte[] tmp
    • random

      private SecureRandom random
  • Constructor Details

    • SecureRandomProvider

      protected SecureRandomProvider()
    • SecureRandomProvider

      protected SecureRandomProvider(String algorithm, String provider)
  • Method Details

    • newRandom

      private static SecureRandom newRandom()
    • newRandom

      private static SecureRandom newRandom(String algorithm, String provider)
    • fill

      public void fill(byte[] bytes, int start, int len)
      Description copied from interface: Random
      Fill part of bytes with random values.
      Specified by:
      fill in interface Random
      Parameters:
      bytes - byte array to be filled.
      start - index to start filling at.
      len - length of segment to fill.
    • fill

      public void fill(byte[] bytes)
      Description copied from interface: Random
      Fill the array of bytes with random values.
      Specified by:
      fill in interface Random
      Parameters:
      bytes - byte array to be filled.