public class SubjectPublicKeyInfo extends ASN1Encodable
The getEncoded() method in the public keys in the JCE produces a DER encoded one of these.
BER, DER
Constructor and Description |
---|
SubjectPublicKeyInfo(AlgorithmIdentifier algId,
byte[] publicKey) |
SubjectPublicKeyInfo(AlgorithmIdentifier algId,
DEREncodable publicKey) |
SubjectPublicKeyInfo(ASN1Sequence seq) |
Modifier and Type | Method and Description |
---|---|
AlgorithmIdentifier |
getAlgorithmId() |
static SubjectPublicKeyInfo |
getInstance(ASN1TaggedObject obj,
boolean explicit) |
static SubjectPublicKeyInfo |
getInstance(Object obj) |
DERObject |
getPublicKey()
for when the public key is an encoded object - if the bitstring
can't be decoded this routine throws an IOException.
|
DERBitString |
getPublicKeyData()
for when the public key is raw bits...
|
DERObject |
toASN1Object()
Produce an object suitable for an ASN1OutputStream.
|
equals, getDEREncoded, getDERObject, getEncoded, getEncoded, hashCode
public SubjectPublicKeyInfo(AlgorithmIdentifier algId, DEREncodable publicKey)
public SubjectPublicKeyInfo(AlgorithmIdentifier algId, byte[] publicKey)
public SubjectPublicKeyInfo(ASN1Sequence seq)
public static SubjectPublicKeyInfo getInstance(ASN1TaggedObject obj, boolean explicit)
public static SubjectPublicKeyInfo getInstance(Object obj)
public AlgorithmIdentifier getAlgorithmId()
public DERObject getPublicKey() throws IOException
IOException
- - if the bit string doesn't represent a DER
encoded object.public DERBitString getPublicKeyData()
public DERObject toASN1Object()
SubjectPublicKeyInfo ::= SEQUENCE { algorithm AlgorithmIdentifier, publicKey BIT STRING }
toASN1Object
in class ASN1Encodable
Copyright © 2015. All rights reserved.