Package org.bouncycastle.pkcs
Class DeltaCertAttributeUtils
- java.lang.Object
-
- org.bouncycastle.pkcs.DeltaCertAttributeUtils
-
public class DeltaCertAttributeUtils extends java.lang.ObjectHelpers for working with the delta certificate request attribute carried by a paired ("chameleon") PKCS#10 request โ see draft-bonnell-lamps-chameleon-certs.
-
-
Constructor Summary
Constructors Constructor Description DeltaCertAttributeUtils()
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static booleanisDeltaRequestSignatureValid(PKCS10CertificationRequest baseRequest, ContentVerifierProvider contentVerifierProvider)Verify the delta signature attached to a base PKCS#10 request.static DeltaCertificateRequestAttributeValuetrimDeltaCertificateRequest(DeltaCertificateRequestAttributeValue delta, PKCS10CertificationRequest baseRequest)Return a copy ofdeltawith subject, signatureAlgorithm and extensions fields stripped when they match the corresponding fields ofbaseRequest.
-
-
-
Method Detail
-
isDeltaRequestSignatureValid
public static boolean isDeltaRequestSignatureValid(PKCS10CertificationRequest baseRequest, ContentVerifierProvider contentVerifierProvider) throws PKCSException
Verify the delta signature attached to a base PKCS#10 request. Reconstructs the delta CertificationRequest from the base โ stripping the delta-signature attribute โ and validates the delta signature with the supplied verifier provider.- Parameters:
baseRequest- the base PKCS#10 request carrying the delta attributes.contentVerifierProvider- provider able to verify the delta signature algorithm.- Returns:
trueif the delta signature is valid,falseotherwise.- Throws:
PKCSException- if the signature cannot be processed.
-
trimDeltaCertificateRequest
public static DeltaCertificateRequestAttributeValue trimDeltaCertificateRequest(DeltaCertificateRequestAttributeValue delta, PKCS10CertificationRequest baseRequest)
Return a copy ofdeltawith subject, signatureAlgorithm and extensions fields stripped when they match the corresponding fields ofbaseRequest.Mirrors the cert-side rule in
DeltaCertificateTool.trimDeltaCertificateDescriptor(org.bouncycastle.asn1.x509.DeltaCertificateDescriptor, org.bouncycastle.asn1.x509.TBSCertificate, org.bouncycastle.asn1.x509.Extensions): draft-bonnell-lamps-chameleon-certs ยง4.1 says the extensions field MUST NOT contain any extension which has the same criticality and DER-encoded value as the base, whose type does not appear in the base, or which is the DCD extension type itself.
-
-