Class CounterSignatureBuilder
java.lang.Object
eu.europa.esig.dss.xades.signature.XAdESBuilder
eu.europa.esig.dss.xades.signature.ExtensionBuilder
eu.europa.esig.dss.xades.signature.CounterSignatureBuilder
The XAdES CounterSignatureBuilder used to create a counter signature
signing a SignatureValue of a parent signature
-
Field Summary
Fields inherited from class eu.europa.esig.dss.xades.signature.ExtensionBuilder
currentSignatureDom, documentAnalyzer, qualifyingPropertiesDom, unsignedPropertiesDom, unsignedSignaturePropertiesDom, xadesSignature
Fields inherited from class eu.europa.esig.dss.xades.signature.XAdESBuilder
certificateVerifier, documentDom, ENCAPSULATED_TIMESTAMP_PREFIX, ID_PREFIX, params, REFERENCED_DATA, TARGET, TIMESTAMP_PREFIX, URI, xadesPath
-
Constructor Summary
ModifierConstructorDescriptionprotected
CounterSignatureBuilder
(CertificateVerifier certificateVerifier) Default constructor -
Method Summary
Modifier and TypeMethodDescriptionbuildCounterSignatureDSSReference
(DSSDocument signatureDocument, XAdESCounterSignatureParameters parameters) The method builds aDSSReference
for a SignatureValue to counter signbuildEmbeddedCounterSignature
(DSSDocument signatureDocument, DSSDocument counterSignature, XAdESCounterSignatureParameters parameters) Embeds and returns the embedded counter signature into the UnsignedProperties of original XAdES signaturegetCanonicalizedSignatureValue
(DSSDocument signatureDocument, XAdESCounterSignatureParameters parameters) Extract a canonicalized SignatureValue element from the provided XAdES signatureMethods inherited from class eu.europa.esig.dss.xades.signature.ExtensionBuilder
alignNodes, ensureSignedDataObjectProperties, ensureUnsignedProperties, ensureUnsignedSignatureProperties, getXadesNamespace, getXmldsigNamespace, indentIfPrettyPrint, initializeSignatureBuilder, removeNode, removeNodes
Methods inherited from class eu.europa.esig.dss.xades.signature.XAdESBuilder
createXmlDocument, getCurrentXAdESElements, getCurrentXAdESPath, getXades141Namespace, incorporateCert, incorporateCertDigest, incorporateDigestMethod, incorporateDigestValue, incorporateDigestValue, incorporateIssuerV1, incorporateIssuerV2, incorporateSPDocSpecification, toXmlIdentifier
-
Constructor Details
-
CounterSignatureBuilder
Default constructor- Parameters:
certificateVerifier
-CertificateVerifier
-
-
Method Details
-
getCanonicalizedSignatureValue
public DSSDocument getCanonicalizedSignatureValue(DSSDocument signatureDocument, XAdESCounterSignatureParameters parameters) Extract a canonicalized SignatureValue element from the provided XAdES signature- Parameters:
signatureDocument
-DSSDocument
to be counter-signedparameters
-XAdESCounterSignatureParameters
- Returns:
DSSDocument
extracted and canonicalized SignatureValue
-
buildCounterSignatureDSSReference
public DSSReference buildCounterSignatureDSSReference(DSSDocument signatureDocument, XAdESCounterSignatureParameters parameters) The method builds aDSSReference
for a SignatureValue to counter sign- Parameters:
signatureDocument
-DSSDocument
document containing a signature being counter signedparameters
-XAdESCounterSignatureParameters
- Returns:
DSSReference
for incorporation into a counter signature
-
buildEmbeddedCounterSignature
public DSSDocument buildEmbeddedCounterSignature(DSSDocument signatureDocument, DSSDocument counterSignature, XAdESCounterSignatureParameters parameters) Embeds and returns the embedded counter signature into the UnsignedProperties of original XAdES signature- Parameters:
signatureDocument
-DSSDocument
the original document containing the signature to be counter signedcounterSignature
-DSSDocument
the counter signatureparameters
-XAdESCounterSignatureParameters
- Returns:
DSSDocument
original signature enveloping thecounterSignature
into the UnsignedProperties
-