Interface CertificationRequest


public interface CertificationRequest
A parsed PKCS#10 certification request (RFC 2986).

The type exposes the request's subject, public key, and requested extensions in ZeroEcho PKIX terms, and gives access to the exact signed bytes so that proof of possession can be verified either with the request's own key (verifySelfSignature()) or with an externally supplied ContentVerifier over certificationRequestInfo() — the latter is how a signing service re-verifies a request without holding the key locally.

  • Method Details

    • subject

      X500Principal subject()
      Returns the requested subject distinguished name.
      Returns:
      the subject DN
    • publicKey

      PublicKey publicKey()
      Returns the subject public key carried by the request.
      Returns:
      the subject public key
    • signatureAlgorithm

      AlgorithmIdentifier signatureAlgorithm()
      Returns the signature algorithm identifier of the request self-signature.
      Returns:
      the signature algorithm identifier
    • requestedSubjectAlternativeNames

      List<GeneralName> requestedSubjectAlternativeNames()
      Returns the requested subject alternative names, if any.
      Returns:
      the requested SANs (possibly empty)
    • requestedExtensions

      List<CertificateExtension> requestedExtensions()
      Returns the requested v3 extensions, if any.
      Returns:
      the requested extensions (possibly empty)
    • attributes

      List<CsrAttribute> attributes()
      Returns the request attributes (excluding the extension-request attribute, which is surfaced via requestedExtensions()).
      Returns:
      the request attributes (possibly empty)
    • rawAttributes

      List<CsrAttribute> rawAttributes()
      Returns every PKCS#10 attribute, including the extension-request attribute, as raw (oid, DER values) pairs without interpreting any extension.

      This gives callers that enforce a strict request grammar full control over attribute cardinality and shape without depending on the toolkit's own extension parsing.

      Returns:
      the raw attributes (possibly empty)
    • subjectPublicKeyInfo

      byte[] subjectPublicKeyInfo()
      Returns the exact DER of the SubjectPublicKeyInfo carried by the request, byte-for-byte as encoded in the request.
      Returns:
      the exact SPKI DER
    • certificationRequestInfo

      byte[] certificationRequestInfo()
      Returns the exact DER of the certificationRequestInfo (the to-be-signed portion of the request).
      Returns:
      the to-be-signed DER
    • signature

      byte[] signature()
      Returns the request self-signature bytes.
      Returns:
      the signature bytes
    • encoded

      byte[] encoded()
      Returns the exact DER encoding of the whole request.
      Returns:
      the request DER
    • verifySelfSignature

      boolean verifySelfSignature()
      Verifies proof of possession by checking the request self-signature against the request's own public key.
      Returns:
      true if the self-signature is valid