Class CertificateExtension
java.lang.Object
eu.europa.esig.dss.model.x509.extension.CertificateExtension
- All Implemented Interfaces:
OidBasedEnum
,OidDescription
,Serializable
- Direct Known Subclasses:
AuthorityInformationAccess
,AuthorityKeyIdentifier
,BasicConstraints
,CertificatePolicies
,CRLDistributionPoints
,ExtendedKeyUsages
,InhibitAnyPolicy
,KeyUsage
,NameConstraints
,OCSPNoCheck
,PolicyConstraints
,QcStatements
,SubjectAlternativeNames
,SubjectKeyIdentifier
,ValidityAssuredShortTerm
Abstract implementation of a certificate extension
- See Also:
-
Constructor Summary
ConstructorDescriptionCertificateExtension
(CertificateExtensionEnum certificateExtensionEnum) Constructor from aCertificateExtensionEnum
Constructor with a certificate extension OID -
Method Summary
Modifier and TypeMethodDescriptionvoid
checkCritical
(CertificateToken certificateToken) Checks and sets whether the certificate extension is criticalThis method returns the literal description of the OIDbyte[]
Returns DER-encoded octets of the certificate extensiongetOid()
This method returns the OID valueboolean
Returns whether the certificate extension is critical or notvoid
setOctets
(byte[] octets) Sets DER-encoded octets of the certificate extension
-
Constructor Details
-
CertificateExtension
Constructor with a certificate extension OID- Parameters:
oid
-String
certificate extension OID
-
CertificateExtension
Constructor from aCertificateExtensionEnum
- Parameters:
certificateExtensionEnum
-CertificateExtensionEnum
-
-
Method Details
-
getOid
Description copied from interface:OidBasedEnum
This method returns the OID value- Specified by:
getOid
in interfaceOidBasedEnum
- Returns:
- the OID value
-
getDescription
Description copied from interface:OidDescription
This method returns the literal description of the OID- Specified by:
getDescription
in interfaceOidDescription
- Returns:
- the OID description
-
isCritical
public boolean isCritical()Returns whether the certificate extension is critical or not- Returns:
- TRUE if the certificate extension is critical, FALSE otherwise
-
checkCritical
Checks and sets whether the certificate extension is critical- Parameters:
certificateToken
-CertificateToken
to check
-
getOctets
public byte[] getOctets()Returns DER-encoded octets of the certificate extension- Returns:
- byte array containing DER-encoded octets of the certificate extension
-
setOctets
public void setOctets(byte[] octets) Sets DER-encoded octets of the certificate extension- Parameters:
octets
- byte array containing DER-encoded octets of the certificate extension
-