java.lang.Object
org.bouncycastle.crypto.CryptoServicesRegistrar

public class CryptoServicesRegistrarextends Object
Registry for cryptographic services and utilities. Provides secure random source and constraint checking functionality.
  • Field Details

    • sr

      private static final SecureRandom sr
      The secure random used when none is configured.
  • Constructor Details

    • CryptoServicesRegistrar

      public CryptoServicesRegistrar()
      Creates an instance, all useful members are static.
  • Method Details

    • checkConstraints

      public static void checkConstraints(CryptoServiceProperties csp)
      Check a service's algorithm strength and key size constraints.
      Parameters:
      csp - the service properties
    • getSecureRandom

      public static SecureRandom getSecureRandom(SecureRandom secureRandom)
      Return the default source of randomness.
      Parameters:
      secureRandom - the secure random to check
      Returns:
      the default SecureRandom