Top Fields Constructors Methods
org.bouncycastle.openssl

public Class PKCS8Generator

extends Object
implements PemObjectGenerator
Class Inheritance
All Implemented Interfaces
org.bouncycastle.util.io.pem.PemObjectGenerator
Known Direct Subclasses
org.bouncycastle.openssl.jcajce.JcaPKCS8Generator
Imports
java.io.ByteArrayOutputStream, .IOException, .OutputStream, org.bouncycastle.asn1.ASN1ObjectIdentifier, .DERNull, org.bouncycastle.asn1.cryptopro.CryptoProObjectIdentifiers, org.bouncycastle.asn1.nist.NISTObjectIdentifiers, org.bouncycastle.asn1.pkcs.EncryptedPrivateKeyInfo, .PKCSObjectIdentifiers, .PrivateKeyInfo, org.bouncycastle.asn1.x509.AlgorithmIdentifier, org.bouncycastle.operator.OutputEncryptor, org.bouncycastle.util.io.pem.PemGenerationException, .PemObject, .PemObjectGenerator

Field Summary

Modifier and TypeField and Description
public static final ASN1ObjectIdentifier
public static final ASN1ObjectIdentifier
public static final ASN1ObjectIdentifier
public static final ASN1ObjectIdentifier
private PrivateKeyInfo
private OutputEncryptor
public static final ASN1ObjectIdentifier
public static final ASN1ObjectIdentifier
public static final ASN1ObjectIdentifier
public static final ASN1ObjectIdentifier
public static final ASN1ObjectIdentifier
public static final ASN1ObjectIdentifier
public static final AlgorithmIdentifier
public static final AlgorithmIdentifier
public static final AlgorithmIdentifier
public static final AlgorithmIdentifier
public static final AlgorithmIdentifier
public static final AlgorithmIdentifier
public static final AlgorithmIdentifier
public static final AlgorithmIdentifier
public static final AlgorithmIdentifier
public static final AlgorithmIdentifier

Constructor Summary

AccessConstructor and Description
public
PKCS8Generator(PrivateKeyInfo key, OutputEncryptor outputEncryptor)

Base constructor.

Method Summary

Modifier and TypeMethod and Description
public PemObject
private PemObject
Inherited from java.lang.Object:
cloneequalsfinalizegetClasshashCodenotifynotifyAlltoStringwaitwaitwait

Field Detail

AES_128_CBCback to summary
public static final ASN1ObjectIdentifier AES_128_CBC
AES_192_CBCback to summary
public static final ASN1ObjectIdentifier AES_192_CBC
AES_256_CBCback to summary
public static final ASN1ObjectIdentifier AES_256_CBC
DES3_CBCback to summary
public static final ASN1ObjectIdentifier DES3_CBC
keyback to summary
private PrivateKeyInfo key
outputEncryptorback to summary
private OutputEncryptor outputEncryptor
PBE_SHA1_2DESback to summary
public static final ASN1ObjectIdentifier PBE_SHA1_2DES
PBE_SHA1_3DESback to summary
public static final ASN1ObjectIdentifier PBE_SHA1_3DES
PBE_SHA1_RC2_128back to summary
public static final ASN1ObjectIdentifier PBE_SHA1_RC2_128
PBE_SHA1_RC2_40back to summary
public static final ASN1ObjectIdentifier PBE_SHA1_RC2_40
PBE_SHA1_RC4_128back to summary
public static final ASN1ObjectIdentifier PBE_SHA1_RC4_128
PBE_SHA1_RC4_40back to summary
public static final ASN1ObjectIdentifier PBE_SHA1_RC4_40
PRF_HMACGOST3411back to summary
public static final AlgorithmIdentifier PRF_HMACGOST3411
PRF_HMACSHA1back to summary
public static final AlgorithmIdentifier PRF_HMACSHA1
PRF_HMACSHA224back to summary
public static final AlgorithmIdentifier PRF_HMACSHA224
PRF_HMACSHA256back to summary
public static final AlgorithmIdentifier PRF_HMACSHA256
PRF_HMACSHA384back to summary
public static final AlgorithmIdentifier PRF_HMACSHA384
PRF_HMACSHA3_224back to summary
public static final AlgorithmIdentifier PRF_HMACSHA3_224
PRF_HMACSHA3_256back to summary
public static final AlgorithmIdentifier PRF_HMACSHA3_256
PRF_HMACSHA3_384back to summary
public static final AlgorithmIdentifier PRF_HMACSHA3_384
PRF_HMACSHA3_512back to summary
public static final AlgorithmIdentifier PRF_HMACSHA3_512
PRF_HMACSHA512back to summary
public static final AlgorithmIdentifier PRF_HMACSHA512

Constructor Detail

PKCS8Generatorback to summary
public PKCS8Generator(PrivateKeyInfo key, OutputEncryptor outputEncryptor)

Base constructor.

Method Detail

generateback to summary
public PemObject generate() throws PemGenerationException

Implements org.bouncycastle.util.io.pem.PemObjectGenerator.generate.

Doc from org.bouncycastle.util.io.pem.PemObjectGenerator.generate.

Generate a PEM object.

Returns:PemObject

the generated object.

Exceptions
PemGenerationException:
on failure.
generateback to summary
private PemObject generate(PrivateKeyInfo key, OutputEncryptor encryptor) throws PemGenerationException