Class PreCertificateBuilder
java.lang.Object
zeroecho.pki.server.ct.PreCertificateBuilder
Builds a CT pre-certificate from a
TBSCertificate by adding the CT poison
extension and signing it with the CA's key, ready for submission to CT logs.
This class delegates entirely to Pkix.buildPreCertificate(byte[], List, ContentSigner); it exists as a
named collaborator so the issuance pipeline can treat pre-certificate construction as
an injected strategy rather than a direct static call.
Thread safety
This class is stateless and thread-safe.
- Since:
- 1.0
-
Method Summary
Modifier and TypeMethodDescriptionstatic PreCertificateResultbuild(byte[] tbsCertificateDer, List<byte[]> issuerChainDer, ContentSigner signer) Builds a CT pre-certificate from aTBSCertificateusing the CA's content signer.
-
Method Details
-
build
public static PreCertificateResult build(byte[] tbsCertificateDer, List<byte[]> issuerChainDer, ContentSigner signer) Builds a CT pre-certificate from aTBSCertificateusing the CA's content signer.The returned
PreCertificateResultcontains the DER-encoded pre-certificate (with the CT poison extension added and signed with the CA key) and the issuer chain. The pre-certificate is ready for submission to one or more CT logs viaCtLogSubmitter.submitAll(byte[], List, List, Instant).- Parameters:
tbsCertificateDer- DER-encodedTBSCertificate; must not benullissuerChainDer- DER-encoded issuer certificate chain, issuer first; must not benullsigner- content signer configured for the issuing CA key; must not benull- Returns:
- pre-certificate DER and its chain
- Throws:
IllegalArgumentException- if pre-certificate construction or signing failsNullPointerException- if any argument isnull- Since:
- 1.0
-