PKCS8Generator (Bouncy Castle Library 1.54 API Specification)
Date: 2015-12-29

org.bouncycastle.openssl

## Class PKCS8Generator

- java.lang.Object
- - org.bouncycastle.openssl.PKCS8Generator

- All Implemented Interfaces:
    org.bouncycastle.util.io.pem.PemObjectGenerator
  Direct Known Subclasses:
    JcaPKCS8Generator

      public class PKCS8Generator
      extends java.lang.Object
      implements org.bouncycastle.util.io.pem.PemObjectGenerator

- - ### Field Summary

    Fields
    Modifier and Type | Field and Description
    --- | ---
    `static org.bouncycastle.asn1.ASN1ObjectIdentifier` | `AES_128_CBC`
    `static org.bouncycastle.asn1.ASN1ObjectIdentifier` | `AES_192_CBC`
    `static org.bouncycastle.asn1.ASN1ObjectIdentifier` | `AES_256_CBC`
    `static org.bouncycastle.asn1.ASN1ObjectIdentifier` | `DES3_CBC`
    `static org.bouncycastle.asn1.ASN1ObjectIdentifier` | `PBE_SHA1_2DES`
    `static org.bouncycastle.asn1.ASN1ObjectIdentifier` | `PBE_SHA1_3DES`
    `static org.bouncycastle.asn1.ASN1ObjectIdentifier` | `PBE_SHA1_RC2_128`
    `static org.bouncycastle.asn1.ASN1ObjectIdentifier` | `PBE_SHA1_RC2_40`
    `static org.bouncycastle.asn1.ASN1ObjectIdentifier` | `PBE_SHA1_RC4_128`
    `static org.bouncycastle.asn1.ASN1ObjectIdentifier` | `PBE_SHA1_RC4_40`

  - ### Constructor Summary

    Constructors
    Constructor and Description
    `PKCS8Generator(org.bouncycastle.asn1.pkcs.PrivateKeyInfo key, OutputEncryptor outputEncryptor)` Base constructor.

  - ### Method Summary

    Methods
    Modifier and Type | Method and Description
    --- | ---
    `org.bouncycastle.util.io.pem.PemObject` | `generate()`

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

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

- - ### Field Detail

    - #### AES_128_CBC

          public static final org.bouncycastle.asn1.ASN1ObjectIdentifier AES_128_CBC

    - #### AES_192_CBC

          public static final org.bouncycastle.asn1.ASN1ObjectIdentifier AES_192_CBC

    - #### AES_256_CBC

          public static final org.bouncycastle.asn1.ASN1ObjectIdentifier AES_256_CBC

    - #### DES3_CBC

          public static final org.bouncycastle.asn1.ASN1ObjectIdentifier DES3_CBC

    - #### PBE_SHA1_RC4_128

          public static final org.bouncycastle.asn1.ASN1ObjectIdentifier PBE_SHA1_RC4_128

    - #### PBE_SHA1_RC4_40

          public static final org.bouncycastle.asn1.ASN1ObjectIdentifier PBE_SHA1_RC4_40

    - #### PBE_SHA1_3DES

          public static final org.bouncycastle.asn1.ASN1ObjectIdentifier PBE_SHA1_3DES

    - #### PBE_SHA1_2DES

          public static final org.bouncycastle.asn1.ASN1ObjectIdentifier PBE_SHA1_2DES

    - #### PBE_SHA1_RC2_128

          public static final org.bouncycastle.asn1.ASN1ObjectIdentifier PBE_SHA1_RC2_128

    - #### PBE_SHA1_RC2_40

          public static final org.bouncycastle.asn1.ASN1ObjectIdentifier PBE_SHA1_RC2_40

  - ### Constructor Detail

    - #### PKCS8Generator

          public PKCS8Generator(org.bouncycastle.asn1.pkcs.PrivateKeyInfo key,
                        OutputEncryptor outputEncryptor)

      Base constructor.

  - ### Method Detail

    - #### generate

          public org.bouncycastle.util.io.pem.PemObject generate()
                                                          throws org.bouncycastle.util.io.pem.PemGenerationException

      Specified by:
        `generate` in interface `org.bouncycastle.util.io.pem.PemObjectGenerator`
      Throws:
        `org.bouncycastle.util.io.pem.PemGenerationException`