Class XmlEvidenceRecordTimeStampSequenceVerifier
java.lang.Object
eu.europa.esig.dss.evidencerecord.common.validation.EvidenceRecordTimeStampSequenceVerifier
eu.europa.esig.dss.evidencerecord.xml.validation.XmlEvidenceRecordTimeStampSequenceVerifier
public class XmlEvidenceRecordTimeStampSequenceVerifier
extends EvidenceRecordTimeStampSequenceVerifier
Verifies ArchiveTimeStampSequence for an XML Evidence Record
-
Field Summary
Fields inherited from class eu.europa.esig.dss.evidencerecord.common.validation.EvidenceRecordTimeStampSequenceVerifier
evidenceRecord
-
Constructor Summary
ConstructorDescriptionXmlEvidenceRecordTimeStampSequenceVerifier
(XmlEvidenceRecord evidenceRecord) Default constructor to instantiate an XML evidence record verifier -
Method Summary
Modifier and TypeMethodDescriptionprotected DSSMessageDigest
computeTimeStampHash
(ArchiveTimeStampObject archiveTimeStamp) Computes hash onarchiveTimeStamp
element provided thearchiveTimeStampChain
's attributesprotected DSSMessageDigest
computeTimeStampSequenceHash
(ArchiveTimeStampChainObject archiveTimeStampChain) Computes hash of currentArchiveTimeStampSequenceElement
protected String
getCanonicalizationMethod
(ArchiveTimeStampChainObject archiveTimeStampChain) Extracts a canonicalization method defined within XMLArchiveTimeStampChainObject
protected DataObjectDigestBuilder
getDataObjectDigestBuilder
(DSSDocument document, ArchiveTimeStampChainObject archiveTimeStampChain) ReturnsDataObjectDigestBuilder
corresponding to the current implementationThis method returns a helper class containing supporting methods for digest computation in relation to an ArchiveTimeStampChainprotected List
<? extends DigestValueGroup> getHashTree
(List<? extends DigestValueGroup> originalHashTree, List<DSSDocument> detachedContents, ManifestFile manifestFile, ArchiveTimeStampChainObject archiveTimeStampChain, DSSMessageDigest lastTimeStampHash, DSSMessageDigest lastTimeStampSequenceHash) This method returns a relevant HashTree, and created a "virtual" HashTree when a HashTree is omitted in the TimeStampMethods inherited from class eu.europa.esig.dss.evidencerecord.common.validation.EvidenceRecordTimeStampSequenceVerifier
checkHashTreeValidity, computeDigestValueGroupHash, getDocumentDigest, getLastTimeStampSequenceHashList, getMatchingDocument, getMatchingDocument, getMatchingManifestEntry, getReferenceValidations, validateArchiveDataObjects, validateArchiveTimeStampDigest, validateArchiveTimeStampSequenceDigest, verify
-
Constructor Details
-
XmlEvidenceRecordTimeStampSequenceVerifier
Default constructor to instantiate an XML evidence record verifier- Parameters:
evidenceRecord
-XmlEvidenceRecord
XML evidence record to be validated
-
-
Method Details
-
getDataObjectDigestBuilder
protected DataObjectDigestBuilder getDataObjectDigestBuilder(DSSDocument document, ArchiveTimeStampChainObject archiveTimeStampChain) Description copied from class:EvidenceRecordTimeStampSequenceVerifier
ReturnsDataObjectDigestBuilder
corresponding to the current implementation- Specified by:
getDataObjectDigestBuilder
in classEvidenceRecordTimeStampSequenceVerifier
- Parameters:
document
-DSSDocument
document to build digest forarchiveTimeStampChain
-ArchiveTimeStampChainObject
of the current hashtree- Returns:
DataObjectDigestBuilder
-
getCanonicalizationMethod
Extracts a canonicalization method defined within XMLArchiveTimeStampChainObject
- Parameters:
archiveTimeStampChain
-ArchiveTimeStampChainObject
to get canonicalization method definition from- Returns:
String
canonicalization method
-
getHashTree
protected List<? extends DigestValueGroup> getHashTree(List<? extends DigestValueGroup> originalHashTree, List<DSSDocument> detachedContents, ManifestFile manifestFile, ArchiveTimeStampChainObject archiveTimeStampChain, DSSMessageDigest lastTimeStampHash, DSSMessageDigest lastTimeStampSequenceHash) Description copied from class:EvidenceRecordTimeStampSequenceVerifier
This method returns a relevant HashTree, and created a "virtual" HashTree when a HashTree is omitted in the TimeStamp- Overrides:
getHashTree
in classEvidenceRecordTimeStampSequenceVerifier
- Parameters:
originalHashTree
- a list ofDigestValueGroup
, representing an original HashTree extracted from a time-stamp tokendetachedContents
- a list ofDSSDocument
s, provided to the validation as a detached contentmanifestFile
-ManifestFile
when presentarchiveTimeStampChain
-ArchiveTimeStampChainObject
archive time-stamp chain containing the time-stamplastTimeStampHash
-DSSMessageDigest
digest of the previous archive-time-stamp, when applicablelastTimeStampSequenceHash
-DSSMessageDigest
digest of the previous archive-time-stamp-sequence, when applicable- Returns:
- a list of
DigestValueGroup
, representing a HashTree to be used for an archive-time-stamp validation
-
computeTimeStampHash
Description copied from class:EvidenceRecordTimeStampSequenceVerifier
Computes hash onarchiveTimeStamp
element provided thearchiveTimeStampChain
's attributes- Specified by:
computeTimeStampHash
in classEvidenceRecordTimeStampSequenceVerifier
- Parameters:
archiveTimeStamp
-ArchiveTimeStampObject
to compute hash on- Returns:
DSSMessageDigest
-
computeTimeStampSequenceHash
protected DSSMessageDigest computeTimeStampSequenceHash(ArchiveTimeStampChainObject archiveTimeStampChain) Description copied from class:EvidenceRecordTimeStampSequenceVerifier
Computes hash of currentArchiveTimeStampSequenceElement
- Specified by:
computeTimeStampSequenceHash
in classEvidenceRecordTimeStampSequenceVerifier
- Parameters:
archiveTimeStampChain
-ArchiveTimeStampChainObject
to compute hash for- Returns:
DSSMessageDigest
-
getEvidenceRecordRenewalDigestBuilderHelper
This method returns a helper class containing supporting methods for digest computation in relation to an ArchiveTimeStampChain
-