Class CAdESCounterSignatureBuilder
java.lang.Object
eu.europa.esig.dss.cades.signature.CAdESCounterSignatureBuilder
The class to build a CAdES counter signature
-
Constructor Summary
ConstructorDescriptionCAdESCounterSignatureBuilder
(CertificateVerifier certificateVerifier) The default constructor -
Method Summary
Modifier and TypeMethodDescriptionaddCounterSignature
(org.bouncycastle.cms.CMSSignedData originalCMSSignedData, CAdESCounterSignatureParameters parameters, SignatureValue signatureValue) Adds a counter signature the provided CMSSignedDataorg.bouncycastle.cms.SignerInformationStore
generateCounterSignature
(org.bouncycastle.cms.SignerInformation signerInformation, CAdESSignatureParameters parameters, CustomContentSigner customContentSigner) Generates a counter-signatureSignerInformationStore
org.bouncycastle.cms.SignerInformation
getSignerInformationToBeCounterSigned
(DSSDocument signatureDocument, CAdESCounterSignatureParameters parameters) Returns aSignerInformation
to be counter-signedvoid
setManifestFile
(ManifestFile manifestFile) Sets a signed manifest file NOTE: ASiC only
-
Constructor Details
-
CAdESCounterSignatureBuilder
The default constructor- Parameters:
certificateVerifier
-CertificateVerifier
-
-
Method Details
-
setManifestFile
Sets a signed manifest file NOTE: ASiC only- Parameters:
manifestFile
-ManifestFile
-
addCounterSignature
public CMSSignedDocument addCounterSignature(org.bouncycastle.cms.CMSSignedData originalCMSSignedData, CAdESCounterSignatureParameters parameters, SignatureValue signatureValue) Adds a counter signature the provided CMSSignedData- Parameters:
originalCMSSignedData
-CMSSignedData
to add a counter signature intoparameters
-CAdESCounterSignatureParameters
signatureValue
-SignatureValue
- Returns:
CMSSignedDocument
with an added counter signature
-
generateCounterSignature
public org.bouncycastle.cms.SignerInformationStore generateCounterSignature(org.bouncycastle.cms.SignerInformation signerInformation, CAdESSignatureParameters parameters, CustomContentSigner customContentSigner) Generates a counter-signatureSignerInformationStore
- Parameters:
signerInformation
-SignerInformation
of a signature to be counter-signedparameters
-CAdESCounterSignatureParameters
customContentSigner
-CustomContentSigner
- Returns:
SignerInformationStore
-
getSignerInformationToBeCounterSigned
public org.bouncycastle.cms.SignerInformation getSignerInformationToBeCounterSigned(DSSDocument signatureDocument, CAdESCounterSignatureParameters parameters) Returns aSignerInformation
to be counter-signed- Parameters:
signatureDocument
-DSSDocument
to find the related signatureparameters
-CAdESCounterSignatureParameters
- Returns:
SignerInformation
-