Package org.bouncycastle.gpg.keybox

## Class CertificateBlob

- java.lang.Object
- - org.bouncycastle.gpg.keybox.Blob
  - - org.bouncycastle.gpg.keybox.KeyBlob
    - - org.bouncycastle.gpg.keybox.CertificateBlob

-     public class CertificateBlob
      extends KeyBlob

  A PGP blob holds key material.

- - ### Field Summary

    - ### Fields inherited from class org.bouncycastle.gpg.keybox.Blob

      `base, length, magicBytes, type, version`

  - ### Method Summary

    All Methods Instance Methods Concrete Methods
    Modifier and Type | Method | Description
    --- | --- | ---
    `byte[]` | `getEncodedCertificate()` | Return the encoded certificate.

    - ### Methods inherited from class org.bouncycastle.gpg.keybox.KeyBlob

      `getAllValidity, getAssignedOwnerTrust, getBlobCreatedAt, getBlobFlags, getChecksum, getExpirationTime, getKeyBytes, getKeyInformation, getKeyNumber, getNewestTimestamp, getNumberOfSignatures, getNumberOfUserIDs, getRecheckAfter, getReserveBytes, getSerialNumber, getUserIds`

    - ### Methods inherited from class org.bouncycastle.gpg.keybox.Blob

      `getType, getVersion`

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

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

- - ### Method Detail

    - #### getEncodedCertificate

          public byte[] getEncodedCertificate()

      Return the encoded certificate.

      This is the raw certificate data, if you are using the JCA then you can convert it back to an X509 Certificate using.

      Example: byte[] certData = keyBlob.getEncodedCertificate(); CertificateFactory factory = CertificateFactory.getInstance("X509"); certificate = factory.generateCertificate(new ByteArrayInputStream(certData));

      Returns: