public class PrivateKeyInfo extends ASN1Object
Constructor and Description |
---|
PrivateKeyInfo(AlgorithmIdentifier algId,
ASN1Encodable privateKey) |
PrivateKeyInfo(AlgorithmIdentifier algId,
ASN1Encodable privateKey,
ASN1Set attributes) |
PrivateKeyInfo(ASN1Sequence seq)
Deprecated.
use PrivateKeyInfo.getInstance()
|
Modifier and Type | Method and Description |
---|---|
AlgorithmIdentifier |
getAlgorithmId()
Deprecated.
use getPrivateKeyAlgorithm()
|
ASN1Set |
getAttributes() |
static PrivateKeyInfo |
getInstance(ASN1TaggedObject obj,
boolean explicit) |
static PrivateKeyInfo |
getInstance(java.lang.Object obj) |
ASN1Primitive |
getPrivateKey()
Deprecated.
use parsePrivateKey()
|
AlgorithmIdentifier |
getPrivateKeyAlgorithm() |
ASN1Encodable |
parsePrivateKey() |
ASN1Primitive |
toASN1Primitive()
write out an RSA private key with its associated information
as described in PKCS8.
|
equals, getEncoded, getEncoded, hasEncodedTagValue, hashCode, toASN1Object
public PrivateKeyInfo(AlgorithmIdentifier algId, ASN1Encodable privateKey) throws java.io.IOException
java.io.IOException
public PrivateKeyInfo(AlgorithmIdentifier algId, ASN1Encodable privateKey, ASN1Set attributes) throws java.io.IOException
java.io.IOException
public PrivateKeyInfo(ASN1Sequence seq)
seq
- public static PrivateKeyInfo getInstance(ASN1TaggedObject obj, boolean explicit)
public static PrivateKeyInfo getInstance(java.lang.Object obj)
public AlgorithmIdentifier getPrivateKeyAlgorithm()
public AlgorithmIdentifier getAlgorithmId()
public ASN1Encodable parsePrivateKey() throws java.io.IOException
java.io.IOException
public ASN1Primitive getPrivateKey()
public ASN1Set getAttributes()
public ASN1Primitive toASN1Primitive()
PrivateKeyInfo ::= SEQUENCE { version Version, privateKeyAlgorithm AlgorithmIdentifier {{PrivateKeyAlgorithms}}, privateKey PrivateKey, attributes [0] IMPLICIT Attributes OPTIONAL } Version ::= INTEGER {v1(0)} (v1,...) PrivateKey ::= OCTET STRING Attributes ::= SET OF Attribute
toASN1Primitive
in interface ASN1Encodable
toASN1Primitive
in class ASN1Object