Enum ExtensionType

java.lang.Object
java.lang.Enum<ExtensionType>
org.cryptacular.x509.ExtensionType
All Implemented Interfaces:
Serializable, Comparable<ExtensionType>, java.lang.constant.Constable

public enum ExtensionType extends Enum<ExtensionType>
Enumeration of X.509v3 extension fields defined in section 4.2 of RFC 2459.
Version:
$Revision: 2745 $
Author:
Middleware Services
  • Enum Constant Details

    • AuthorityInformationAccess

      public static final ExtensionType AuthorityInformationAccess
      AuthorityInfoAccess extension field.
    • AuthorityKeyIdentifier

      public static final ExtensionType AuthorityKeyIdentifier
      AuthorityKeyIdentifier extension field.
    • BasicConstraints

      public static final ExtensionType BasicConstraints
      BasicConstraints extension field.
    • CertificatePolicies

      public static final ExtensionType CertificatePolicies
      CertificatePolicies extension field.
    • CRLDistributionPoints

      public static final ExtensionType CRLDistributionPoints
      CRLDistributionPoints extension field.
    • ExtendedKeyUsage

      public static final ExtensionType ExtendedKeyUsage
      ExtendedKeyUsage extension field.
    • IssuerAlternativeName

      public static final ExtensionType IssuerAlternativeName
      IssuerAlternativeName extension field.
    • KeyUsage

      public static final ExtensionType KeyUsage
      KeyUsage extension field.
    • NameConstraints

      public static final ExtensionType NameConstraints
      NameConstraints extension field.
    • PolicyConstraints

      public static final ExtensionType PolicyConstraints
      PolicyConstraints extension field.
    • PolicyMappings

      public static final ExtensionType PolicyMappings
      PolicyMappings extension field.
    • PrivateKeyUsagePeriod

      public static final ExtensionType PrivateKeyUsagePeriod
      PrivateKeyUsage extension field.
    • SubjectAlternativeName

      public static final ExtensionType SubjectAlternativeName
      SubjectAlternativeName extension field.
    • SubjectKeyIdentifier

      public static final ExtensionType SubjectKeyIdentifier
      SubjectKeyIdentifier extension field.
    • SubjectDirectoryAttributes

      public static final ExtensionType SubjectDirectoryAttributes
      SubjectDirectoryAttributes extension field.
  • Method Details

    • values

      public static ExtensionType[] values()
      Returns an array containing the constants of this enum type, in the order they are declared.
      Returns:
      an array containing the constants of this enum type, in the order they are declared
    • valueOf

      public static ExtensionType valueOf(String name)
      Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)
      Parameters:
      name - the name of the enum constant to be returned.
      Returns:
      the enum constant with the specified name
      Throws:
      IllegalArgumentException - if this enum type has no constant with the specified name
      NullPointerException - if the argument is null
    • fromOid

      public static ExtensionType fromOid(String oid)
      Gets the extension by OID.
      Parameters:
      oid - Extension OID value.
      Returns:
      Extension with given OID value.
      Throws:
      IllegalArgumentException - If no extension with given OID exists.
    • fromName

      public static ExtensionType fromName(String name)
      Gets the extension by name.
      Parameters:
      name - Case-sensitive X.509v3 extension name. The acceptable case of extension names is governed by conventions in RFC 2459.
      Returns:
      Extension with given name.
      Throws:
      IllegalArgumentException - If no extension with given name exists.
    • isCritical

      public boolean isCritical()
      Returns:
      True if extension MUST or SHOULD be marked critical under general circumstances according to RFC 2459, false otherwise.
    • getOid

      public String getOid()
      Returns:
      OID value of extension field.