Class PdfCMSRevision

java.lang.Object
eu.europa.esig.dss.pdf.PdfCMSRevision
All Implemented Interfaces:
PdfRevision, Serializable
Direct Known Subclasses:
PdfDocTimestampRevision, PdfSignatureRevision

public abstract class PdfCMSRevision extends Object implements PdfRevision
Defines a PDF revision containing a CMS data (signature/timestamp)
See Also:
  • Constructor Details

    • PdfCMSRevision

      protected PdfCMSRevision(PdfSignatureDictionary signatureDictionary, List<PdfSignatureField> signatureFields, DSSDocument signedContent, DSSDocument previousRevision, boolean coverAllOriginalBytes)
      Default constructor
      Parameters:
      signatureDictionary - The signature dictionary
      signatureFields - the list of PdfSignatureFields
      signedContent - DSSDocument the signed content
      previousRevision - DSSDocument the originally signed PDF revision (before signature)
      coverAllOriginalBytes - true if the signature covers all original bytes
  • Method Details

    • getSignedData

      public DSSDocument getSignedData()
      Gets the current signature revision
      Returns:
      DSSDocument
    • getPreviousRevision

      public DSSDocument getPreviousRevision()
      Gets PDF revision preceding to the current signature revision
      Returns:
      DSSDocument
    • getPdfSigDictInfo

      public PdfSignatureDictionary getPdfSigDictInfo()
      Description copied from interface: PdfRevision
      Returns a PDF Signature Dictionary info container
      Specified by:
      getPdfSigDictInfo in interface PdfRevision
      Returns:
      PdfSignatureDictionary
    • getByteRange

      public ByteRange getByteRange()
      Gets the signed byte range
      Returns:
      ByteRange
    • getSigningDate

      public Date getSigningDate()
      Gets the claimed signing time
      Returns:
      Date
    • areAllOriginalBytesCovered

      public boolean areAllOriginalBytesCovered()
      Gets of the all PDF's content is signed
      Returns:
      TRUE if the whole PDF is signed, FALSE otherwise
    • getFields

      public List<PdfSignatureField> getFields()
      Description copied from interface: PdfRevision
      Returns a list of signature fields that refer the current object
      Specified by:
      getFields in interface PdfRevision
      Returns:
      list of PdfSignatureFields
    • getCMSSignedData

      public org.bouncycastle.cms.CMSSignedData getCMSSignedData()
      Gets the CMSSignedData
      Returns:
      CMSSignedData
    • getModificationDetection

      public PdfModificationDetection getModificationDetection()
      Description copied from interface: PdfRevision
      Returns an information about changes made in the document
      Specified by:
      getModificationDetection in interface PdfRevision
      Returns:
      PdfModificationDetection
    • setModificationDetection

      public void setModificationDetection(PdfModificationDetection modificationDetection)
      Sets the PdfModificationDetection result
      Parameters:
      modificationDetection - PdfModificationDetection