Package eu.europa.esig.dss.diagnostic
Class TimestampWrapper
java.lang.Object
eu.europa.esig.dss.diagnostic.AbstractTokenProxy
eu.europa.esig.dss.diagnostic.TimestampWrapper
- All Implemented Interfaces:
TokenProxy
Provides a user-friendly interface for dealing with JAXB
XmlTimestamp object-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionbooleanIndicates if any PDF modifications have been detectedReturns FoundCertificatesProxy to access embedded certificatesReturns FoundRevocationsProxy to access embedded revocation dataReturns a list of all OrphanTokensReturns archive timestamp type, if applicable NOTE: returns null for non archive timestampsbyte[]Returns binaries of the token, when presentReturns /ContactInfo parameter valueprotected XmlBasicSignatureReturns a basic signature validationprotected List<XmlChainItem>Returns the token's certificate chainprotected XmlSigningCertificateReturns the signing certificate of the tokenReturns digest algorithm and value of the timestamp token binaries, when definedReturns a list of DigestMatchers used in the validation process for a signature or timestampGets name of the timestamp file, when applicableReturns /Filter parameter valueReturns the first signature field namegetId()Returns the unique identifier of the objectReturns message-imprintXmlDigestMatcherThis method returns a list of field names modified after the current timestamp's revisionReturns a list of changes occurred in a PDF after the current timestamp's revision associated with annotation(s) modificationReturns a list of PDF annotation overlap concerned pagesReturns a list of changes occurred in a PDF after the current timestamp's revision associated with a signature/document extensionReturns a list of pages missing/added to the final revision in a comparison with a signed oneReturns a PAdES-specific PDF Revision info NOTE: applicable only for PAdESReturns a list of changes occurred in a PDF after the current timestamp's revision associated with a signature creation, form fillingReturns a list of undefined changes occurred in a PDF after the current timestamp's revisionReturns a list of PDF visual difference concerned pagesReturns the indicated production time of the timestampReturns /Reason parameter valueReturns /ByteRange parameter valueReturns /Type parameter valueReturns a list of signature field names, where the signature is referenced fromReturns a list if Signer Infos (Signer Information Store) from CAdES CMS Signed DataReturns /Name parameter valueReturns /SubFilter parameter valueReturns a list of certificates covered be the current timestampReturns a complete list of allXmlTimestampedObjects covered by the timestampReturns a list of OrphanCertificateTokensReturns a list of OrphanRevocationTokensReturns a list of revocation data covered be the current timestampReturns a list ofSignatureWrappers covered be the current timestampReturns a list of Signed data covered be the current timestampReturns a list of timestamps covered be the current timestampReturns Timestamp's Signature ScopesGet TSA General Name valuegetType()Returns the type of the timestampbooleanIndicates if the message-imprint is found (all the required data for message-imprint computation is present)booleanIndicates if the message-imprint is intact (matches the computed message-imprint)booleanIndicates if the signing certificate reference is present within the timestamp token and matches the actual signing certificatebooleanChecks if the content of TSTInfo.tsa field matches the timestamp's issuer distinguishing name, without taking order into accountbooleanChecks if the content and the order of TSTInfo.tsa field match the timestamp's issuer distinguishing namebooleanChecks if the tsa field of TSTInfo is presentMethods inherited from class eu.europa.esig.dss.diagnostic.AbstractTokenProxy
arePdfModificationsDetected, equals, getCertificateChain, getDigestAlgorithm, getEncryptionAlgorithm, getKeyLengthUsedToSignThisToken, getMaskGenerationFunction, getModifiedFieldNames, getPdfAnnotationChanges, getPdfAnnotationsOverlapConcernedPages, getPdfExtensionChanges, getPdfObjectModifications, getPdfPageDifferenceConcernedPages, getPdfSignatureOrFormFillChanges, getPdfUndefinedChanges, getPdfVisualDifferenceConcernedPages, getSignatureAlgorithm, getSigningCertificate, getSigningCertificatePublicKey, getSigningCertificateReference, getSigningCertificateReferences, hashCode, isCertificateChainFromTrustedStore, isSignatureIntact, isSignatureValid, isSigningCertificateReferencePresent, isSigningCertificateReferenceUnique, isTrustedChain, toString
-
Constructor Details
-
TimestampWrapper
Default constructor- Parameters:
timestamp-XmlTimestamp
-
-
Method Details
-
getId
Description copied from interface:TokenProxyReturns the unique identifier of the object- Returns:
Stringid
-
getCurrentBasicSignature
Description copied from class:AbstractTokenProxyReturns a basic signature validation- Specified by:
getCurrentBasicSignaturein classAbstractTokenProxy- Returns:
XmlBasicSignature
-
getCurrentCertificateChain
Description copied from class:AbstractTokenProxyReturns the token's certificate chain- Specified by:
getCurrentCertificateChainin classAbstractTokenProxy- Returns:
- a list of
XmlChainItems
-
getCurrentSigningCertificate
Description copied from class:AbstractTokenProxyReturns the signing certificate of the token- Specified by:
getCurrentSigningCertificatein classAbstractTokenProxy- Returns:
XmlSigningCertificate
-
foundCertificates
Description copied from interface:TokenProxyReturns FoundCertificatesProxy to access embedded certificates- Specified by:
foundCertificatesin interfaceTokenProxy- Overrides:
foundCertificatesin classAbstractTokenProxy- Returns:
FoundCertificatesProxy
-
foundRevocations
Description copied from interface:TokenProxyReturns FoundRevocationsProxy to access embedded revocation data- Specified by:
foundRevocationsin interfaceTokenProxy- Overrides:
foundRevocationsin classAbstractTokenProxy- Returns:
FoundRevocationsProxy
-
getType
Returns the type of the timestamp- Returns:
TimestampType
-
getArchiveTimestampType
Returns archive timestamp type, if applicable NOTE: returns null for non archive timestamps- Returns:
ArchiveTimestampType
-
getProductionTime
Returns the indicated production time of the timestamp- Returns:
Date
-
getMessageImprint
Returns message-imprintXmlDigestMatcher- Returns:
XmlDigestMatcher
-
isMessageImprintDataFound
public boolean isMessageImprintDataFound()Indicates if the message-imprint is found (all the required data for message-imprint computation is present)- Returns:
- TRUE if the message-imprint data is found, FALSE otherwise
-
isMessageImprintDataIntact
public boolean isMessageImprintDataIntact()Indicates if the message-imprint is intact (matches the computed message-imprint)- Returns:
- TRUE if the message-imprint data is intact, FALSE otherwise
-
getFilename
Gets name of the timestamp file, when applicable- Returns:
Stringfile name
-
getDigestMatchers
Description copied from interface:TokenProxyReturns a list of DigestMatchers used in the validation process for a signature or timestamp- Specified by:
getDigestMatchersin interfaceTokenProxy- Overrides:
getDigestMatchersin classAbstractTokenProxy- Returns:
- a list of
XmlDigestMatchers
-
getTimestampedObjects
Returns a complete list of allXmlTimestampedObjects covered by the timestamp- Returns:
- list of
XmlTimestampedObjects
-
getTimestampedSignatures
Returns a list ofSignatureWrappers covered be the current timestamp- Returns:
- list of
SignatureWrappers
-
getTimestampedCertificates
Returns a list of certificates covered be the current timestamp- Returns:
- list of
CertificateWrappers
-
getTimestampedRevocations
Returns a list of revocation data covered be the current timestamp- Returns:
- list of
RevocationWrappers
-
getTimestampedTimestamps
Returns a list of timestamps covered be the current timestamp- Returns:
- list of
TimestampWrappers
-
getTimestampedSignedData
Returns a list of Signed data covered be the current timestamp- Returns:
- list of
SignerDataWrappers
-
isSigningCertificateIdentified
public boolean isSigningCertificateIdentified()Indicates if the signing certificate reference is present within the timestamp token and matches the actual signing certificate- Returns:
- TRUE if the signing certificate is unambiguously identified, FALSE otherwise
-
getAllTimestampedOrphanTokens
Returns a list of all OrphanTokens- Returns:
- list of
OrphanTokenWrappers
-
getTimestampedOrphanCertificates
Returns a list of OrphanCertificateTokens- Returns:
- list of orphan certificates
-
getTimestampedOrphanRevocations
Returns a list of OrphanRevocationTokens- Returns:
- list of orphan revocations
-
getBinaries
public byte[] getBinaries()Description copied from class:AbstractTokenProxyReturns binaries of the token, when present- Specified by:
getBinariesin classAbstractTokenProxy- Returns:
- a byte array
-
getDigestAlgoAndValue
Returns digest algorithm and value of the timestamp token binaries, when defined- Returns:
XmlDigestAlgoAndValue
-
getPDFRevision
Returns a PAdES-specific PDF Revision info NOTE: applicable only for PAdES- Returns:
XmlPDFRevision
-
arePdfModificationsDetected
public boolean arePdfModificationsDetected()Indicates if any PDF modifications have been detected- Returns:
- TRUE if any potential PDF modifications have been detected between different revisions, FALSE otherwise
-
getPdfAnnotationsOverlapConcernedPages
Returns a list of PDF annotation overlap concerned pages- Returns:
- a list of page numbers
-
getPdfVisualDifferenceConcernedPages
Returns a list of PDF visual difference concerned pages- Returns:
- a list of page numbers
-
getPdfPageDifferenceConcernedPages
Returns a list of pages missing/added to the final revision in a comparison with a signed one- Returns:
- a list of page numbers
-
getPdfExtensionChanges
Returns a list of changes occurred in a PDF after the current timestamp's revision associated with a signature/document extension- Returns:
- a list of
XmlObjectModifications
-
getPdfSignatureOrFormFillChanges
Returns a list of changes occurred in a PDF after the current timestamp's revision associated with a signature creation, form filling- Returns:
- a list of
XmlObjectModifications
-
getPdfAnnotationChanges
Returns a list of changes occurred in a PDF after the current timestamp's revision associated with annotation(s) modification- Returns:
- a list of
XmlObjectModifications
-
getPdfUndefinedChanges
Returns a list of undefined changes occurred in a PDF after the current timestamp's revision- Returns:
- a list of
XmlObjectModifications
-
getModifiedFieldNames
This method returns a list of field names modified after the current timestamp's revision- Returns:
- a list of
Strings
-
getFirstFieldName
Returns the first signature field name- Returns:
Stringfield name
-
getSignatureFieldNames
Returns a list of signature field names, where the signature is referenced from- Returns:
- a list of
Stringsignature field names
-
getSignatureInformationStore
Returns a list if Signer Infos (Signer Information Store) from CAdES CMS Signed Data- Returns:
- list of
XmlSignerInfos
-
isTSAGeneralNamePresent
public boolean isTSAGeneralNamePresent()Checks if the tsa field of TSTInfo is present- Returns:
- TRUE if the TSTInfo.tsa is present, FALSE otherwise
-
getTSAGeneralNameValue
Get TSA General Name value- Returns:
Stringrepresenting a TSTInfo.tsa field when present, null otherwise
-
isTSAGeneralNameMatch
public boolean isTSAGeneralNameMatch()Checks if the content of TSTInfo.tsa field matches the timestamp's issuer distinguishing name, without taking order into account- Returns:
- TRUE if the TSTInfo.tsa field value matches the timestamp's issuer name, FALSE otherwise
-
isTSAGeneralNameOrderMatch
public boolean isTSAGeneralNameOrderMatch()Checks if the content and the order of TSTInfo.tsa field match the timestamp's issuer distinguishing name- Returns:
- TRUE if the TSTInfo.tsa field value and order match the timestamp's issuer name, FALSE otherwise
-
getTimestampScopes
Returns Timestamp's Signature Scopes- Returns:
- a list of
XmlSignatureScopes
-
getSignerName
Returns /Name parameter value- Returns:
String
-
getSignatureDictionaryType
Returns /Type parameter value- Returns:
String
-
getFilter
Returns /Filter parameter value- Returns:
String
-
getSubFilter
Returns /SubFilter parameter value- Returns:
String
-
getContactInfo
Returns /ContactInfo parameter value- Returns:
String
-
getReason
Returns /Reason parameter value- Returns:
String
-
getSignatureByteRange
Returns /ByteRange parameter value- Returns:
String
-