Package org.bouncycastle.crypto.util

## Class AlgorithmIdentifierFactory

- java.lang.Object
- - org.bouncycastle.crypto.util.AlgorithmIdentifierFactory

-     public class AlgorithmIdentifierFactory
      extends java.lang.Object

  Factory methods for common AlgorithmIdentifiers.

- - ### Method Summary

    All Methods Static Methods Concrete Methods
    Modifier and Type | Method | Description
    --- | --- | ---
    `static AlgorithmIdentifier` | `generateEncryptionAlgID​(ASN1ObjectIdentifier encryptionOID, int keySize, java.security.SecureRandom random)` | Create an AlgorithmIdentifier for the passed in encryption algorithm.

    - ### Methods inherited from class java.lang.Object

      `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- - ### Method Detail

    - #### generateEncryptionAlgID

          public static AlgorithmIdentifier generateEncryptionAlgID​(ASN1ObjectIdentifier encryptionOID,
                                                                    int keySize,
                                                                    java.security.SecureRandom random)
                                                             throws java.lang.IllegalArgumentException

      Create an AlgorithmIdentifier for the passed in encryption algorithm.
      Parameters:
        `encryptionOID` - OID for the encryption algorithm
        `keySize` - key size in bits (-1 if unknown)
        `random` - SecureRandom to use for parameter generation.
      Returns:
        a full AlgorithmIdentifier including parameters
      Throws:
        `java.lang.IllegalArgumentException` - if encryptionOID cannot be matched