Class AuthorityKeyIdentifierExtension

  • All Implemented Interfaces:
    java.io.Serializable

    @NotMutable
    @ThreadSafety(level=COMPLETELY_THREADSAFE)
    public final class AuthorityKeyIdentifierExtension
    extends X509CertificateExtension
    This class provides an implementation of the authority key identifier X.509 certificate extension as described in RFC 5280 section 4.2.1.1. The OID for this extension is 2.5.29.35 and the value has the following encoding:
       AuthorityKeyIdentifier ::= SEQUENCE {
          keyIdentifier             [0] KeyIdentifier           OPTIONAL,
          authorityCertIssuer       [1] GeneralNames            OPTIONAL,
          authorityCertSerialNumber [2] CertificateSerialNumber OPTIONAL  }
     
    The actual format of the key identifier is not specified, although RFC 5280 does specify a couple of possibilities.
    See Also:
    Serialized Form
    • Method Detail

      • getKeyIdentifier

        @Nullable
        public ASN1OctetString getKeyIdentifier()
        Retrieves the key identifier for this extension, if available.
        Returns:
        The key identifier for this extension, or null if it was not included in the extension.
      • getAuthorityCertIssuer

        @Nullable
        public GeneralNames getAuthorityCertIssuer()
        Retrieves the general names for the authority certificate, if available.
        Returns:
        The general names for the authority certificate, or null if it was not included in the extension.
      • getAuthorityCertSerialNumber

        @Nullable
        public java.math.BigInteger getAuthorityCertSerialNumber()
        Retrieves the serial number for the authority certificate, if available.
        Returns:
        The serial number for the authority certificate, or null if it was not included in the extension.
      • toString

        public void toString​(@NotNull
                             java.lang.StringBuilder buffer)
        Appends a string representation of this certificate extension to the provided buffer.
        Overrides:
        toString in class X509CertificateExtension
        Parameters:
        buffer - The buffer to which the information should be appended.