X509Cert

data class X509Cert(val encoded: ByteString) : X509Signed

A data type for a X.509 certificate.

Parameters

encoded

the bytes of the X.509 certificate in DER encoding.

Constructors

Link copied to clipboard
constructor(encoded: ByteString)

Types

Link copied to clipboard
class Builder(publicKey: EcPublicKey, signingKey: AsymmetricKey, serialNumber: ASN1Integer, subject: X500Name, issuer: X500Name, validFrom: Instant, validUntil: Instant) : X509SignedBuilder<X509Cert.Builder>

Builder for X.509 certificate.

Link copied to clipboard
object Companion

Properties

Link copied to clipboard

The authority key identifier (OID 2.5.29.35), or null if not present in the certificate.

Link copied to clipboard

The OIDs for X.509 extensions which are marked as critical.

Link copied to clipboard

The public key in the certificate, as an Elliptic Curve key.

Link copied to clipboard
open override val encoded: ByteString
Link copied to clipboard

The list of decoded extensions information.

Link copied to clipboard

The issuer of the certificate.

Link copied to clipboard
val X509Cert.javaX509Certificate: <Error class: unknown class>

The Java X509 certificate from the encoded certificate data.

Link copied to clipboard

The key usage (OID 2.5.29.15) or the empty set if not present.

Link copied to clipboard

The OIDs for X.509 extensions which are not marked as critical.

Link copied to clipboard

The certificate serial number.

Link copied to clipboard

The certificate or CRL signature.

Link copied to clipboard

The signature algorithm for the certificate or CRL as Algorithm.

Link copied to clipboard

The signature algorithm for the CRL as OID string.

Link copied to clipboard

The subject of the certificate.

Link copied to clipboard

The subject key identifier (OID 2.5.29.14), or null if not present in the certificate.

Link copied to clipboard

The bytes of TBS sequence.

Link copied to clipboard

The point in time where the certificate is valid until.

Link copied to clipboard

The point in time where the certificate is valid from.

Link copied to clipboard

The certificate version.

Functions

Link copied to clipboard
Link copied to clipboard

Gets the bytes of a X.509 extension.

Link copied to clipboard
Link copied to clipboard
fun toPem(): String

Encode this certificate or CRL in PEM format

Link copied to clipboard
fun verify(publicKey: EcPublicKey)

Checks if the certificate or CRL was signed with a given key.