Class X509CertificateExtension

java.lang.Object
com.unboundid.util.ssl.cert.X509CertificateExtension
All Implemented Interfaces:
Serializable
Direct Known Subclasses:
AuthorityKeyIdentifierExtension, BasicConstraintsExtension, CRLDistributionPointsExtension, ExtendedKeyUsageExtension, GeneralAlternativeNameExtension, KeyUsageExtension, SubjectKeyIdentifierExtension

This class represents a data structure that holds information about an X.509 certificate extension.
See Also:
  • Constructor Details

    • X509CertificateExtension

      Creates a new X.509 certificate extension that wraps the provided extension.
      Parameters:
      extension - The extension to wrap.
    • X509CertificateExtension

      public X509CertificateExtension(@NotNull OID oid, boolean isCritical, @NotNull byte[] value)
      Creates a new X.509 certificate extension with the provided information.
      Parameters:
      oid - The OID for this extension.
      isCritical - Indicates whether this extension is considered critical.
      value - The value for this extension.
  • Method Details

    • getOID

      @NotNull public final OID getOID()
      Retrieves the OID for this extension.
      Returns:
      The OID for this extension.
    • isCritical

      public final boolean isCritical()
      Indicates whether this extension is considered critical.
      Returns:
      true if this extension is considered critical, or false if not.
    • getValue

      @NotNull public final byte[] getValue()
      Retrieves the value for this extension.
      Returns:
      The value for this extension.
    • getExtensionName

      Retrieves the name for this extension.
      Returns:
      The name for this extension.
    • toString

      @NotNull public final String toString()
      Retrieves a string representation of this extension.
      Overrides:
      toString in class Object
      Returns:
      A string representation of this extension.
    • toString

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