be.cardon.asn1.x509
Class SubjectPublicKeyInfo
java.lang.Object
org.bouncycastle.asn1.ASN1Encodable
be.cardon.asn1.x509.SubjectPublicKeyInfo
- All Implemented Interfaces:
- org.bouncycastle.asn1.DEREncodable
public class SubjectPublicKeyInfo
- extends org.bouncycastle.asn1.ASN1Encodable
The object that contains the public key stored in a certficate.
The getEncoded() method in the public keys in the JCE produces a DER
encoded one of these.
Fields inherited from class org.bouncycastle.asn1.ASN1Encodable |
BER, DER |
Methods inherited from class org.bouncycastle.asn1.ASN1Encodable |
equals, getDEREncoded, getDERObject, getEncoded, getEncoded, hashCode |
Methods inherited from class java.lang.Object |
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait |
SubjectPublicKeyInfo
public SubjectPublicKeyInfo(AlgorithmIdentifier algId,
org.bouncycastle.asn1.DEREncodable publicKey)
SubjectPublicKeyInfo
public SubjectPublicKeyInfo(AlgorithmIdentifier algId,
byte[] publicKey)
SubjectPublicKeyInfo
public SubjectPublicKeyInfo(org.bouncycastle.asn1.ASN1Sequence seq)
getInstance
public static SubjectPublicKeyInfo getInstance(org.bouncycastle.asn1.ASN1TaggedObject obj,
boolean explicit)
getInstance
public static SubjectPublicKeyInfo getInstance(java.lang.Object obj)
getAlgorithmId
public AlgorithmIdentifier getAlgorithmId()
getPublicKey
public org.bouncycastle.asn1.DERObject getPublicKey()
throws java.io.IOException
- for when the public key is an encoded object - if the bitstring
can't be decoded this routine throws an IOException.
- Throws:
java.io.IOException
- - if the bit string doesn't represent a DER
encoded object.
getPublicKeyData
public org.bouncycastle.asn1.DERBitString getPublicKeyData()
- for when the public key is raw bits...
toASN1Object
public org.bouncycastle.asn1.DERObject toASN1Object()
- Produce an object suitable for an ASN1OutputStream.
SubjectPublicKeyInfo ::= SEQUENCE {
algorithm AlgorithmIdentifier,
publicKey BIT STRING }
- Specified by:
toASN1Object
in class org.bouncycastle.asn1.ASN1Encodable