On 07/23/2010 10:24 PM, Kathir wrote:
I am copying a pdf with signature to a new pdf. Using PdfCopyFields,
the form fields are copied and everything looks to be fine.
But when I tried to open the signature in Acro Reader, it says invalid
or corrupt signature. The code is like this,
PdfCopyFields copy = *new* PdfCopyFields(*new*
FileOutputStream("C:/Temp/AcroForms/concatenatedPDF.pdf"));
copy._open_();
copy_._addDocument(_reader1_);
copy_._addDocument(_reader2_);
copy._close_();
I believe something is missing in my code. Not sure.
Any help, please.
The code is fine, but your assumption is wrong.
If you think you can concatenate documents with signatures KEEPING THOSE
SIGNATURES VALID, than you should reconsider. Being able to do that
would defy the whole purpose of signatures.
A signed PDF is a finished PDF. Whenever you change anything to that
PDF, the signature MUST BE INVALID.
Copying a PDF with a signature to a new PDF is 'changing the PDF'.
In other words: you are trying to achieve something that is impossible
and undesirable.
The only thing you can do, is to create a new revision by adding stuff
to the PDF in 'append mode'.
For instance: you can create a PDF with a certifying signature (one and
only one per document), and then let different people append the PDF by
adding ordinary ('receiver') signatures.
Whoever looks at the PDF, can perfectly verify which signatures belong
to which revision. That isn't possible if you try to combine different
documents with different signatures as you are trying to achieve.
------------------------------------------------------------------------------
This SF.net email is sponsored by Sprint
What will you do first with EVO, the first 4G phone?
Visit sprint.com/first -- http://p.sf.net/sfu/sprint-com-first
_______________________________________________
iText-questions mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/itext-questions
Buy the iText book: http://www.itextpdf.com/book/
Check the site with examples before you ask questions:
http://www.1t3xt.info/examples/
You can also search the keywords list: http://1t3xt.info/tutorials/keywords/