1

Is it possible to extract the visible signature (image of capture) of an signed PDF with itext?

Workflow:

  1. list all signatures of a file
  2. show with signatures include an visible signature
  3. show which are valid
  4. extract images of signatures (need to extract correct image for each signature)

1+3:

for (String name:af.getSignatureNames()) {
    AcroFields af = reader.getAcroFields();
    PdfPKCS7 pk = af.verifySignature(name);
}

2: will be solved with 4

4: Here begins the trouble. How is it possible to get the link to the correct field (annotation) and how can I render the embedded data as image (could also be implemented with an external image libary if needed).

I've found out how to get the Item, but not a link to Image Stream or PdfSignatureAppearance:

Item field = af.getFieldItem(name);

Thanks for your help. Greets.

ctvoigt
  • 125
  • 2
  • 8
  • iText does not provide bitmap rendering capabilities out of the box. – mkl Jun 17 '13 at 12:44
  • 1
    Found a solution with my prefered PDF framework (PDFBox): http://stackoverflow.com/questions/16949888/get-visible-signature-from-a-pdf-using-pdfbox – ctvoigt Jun 17 '13 at 13:39

0 Answers0