  | Mailing List | | Home | | Forum Home | | JBoss - Java Application Server | | Tomcat - JSP/Servlet container | | Struts - A MVC web framework | | iText - An open source PDF Java Library | | JDOM - JDOM XML Parser | | JSP - A mailing list about Java Server Pages specification and reference | | J2EE - A mailing list for Java(tm) 2 Platform, Enterprise Edition | | J2EE Pattern - An interest list for Sun Java Center J2EE Pattern Catalog | | Servlet - A mailing list for discussion about Sun Microsystem's Java Servlet API Technology | |
Struts & Hibernate
|
|
|
  | | | -none- | -none- 2007-10-02 - By webtom
Back
Hi,
i try to implement the following steps: 1) reading a signed pdf 2) adding a javascript code to the pdf and 3) printing the pdf to the default printer.
... try { PdfReader reader = new PdfReader(pdfByteArray); //pdfByteArray represents the content of pdf file PdfStamper stamper = new PdfStamper(reader, outputStream); stamper.addJavaScript("this.print(false);"); stamper.close(); } catch (Exception e) {...} ...
After executing the java code the signed document is printed but the signature is not valid. If i don't add the javascript code the pdf is displayed by acrobat reader within the browser but the signature is also invalid! (Error message: byte range of the signature is not valid.)
My questions: 1) How is it possible to read a signed pdf document without destroying the signature? 2) Is there a possibility to add javascript code so that the signature keeps valid?
Thanks for your hints, Tom -- View this message in context: http://www.nabble.com/Problem-with-signed-PDF -tf4554569.html#a12997705 Sent from the iText - General mailing list archive at Nabble.com.
-- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---- ----- This SF.net email is sponsored by: Microsoft Defy all challenges. Microsoft(R) Visual Studio 2005. http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/ __ ____ ____ ____ ____ ____ ____ ____ ____ ____ iText-questions mailing list iText-questions@(protected) https://lists.sourceforge.net/lists/listinfo/itext-questions Buy the iText book: http://itext.ugent.be/itext-in-action/
|
|
 |