The problem is the <</NeedAppearances true>> in the acroforms
dictionary. If it's not there the signature will appear.

Paulo 

> -----Original Message-----
> From: [EMAIL PROTECTED] 
> [mailto:[EMAIL PROTECTED] On 
> Behalf Of Andreas Homrighausen
> Sent: Tuesday, May 02, 2006 7:38 AM
> To: [email protected]
> Subject: Re: [iText-questions] Signing pdf documents 
> containing forms does not work-Sorry First one without content?!
> 
> Hi!
> Thank you all for your help! :)
> I've installed Foxit PDF Reader and this tool shows the signature!
> It's hard to believe but this strange signature-behaviour indicates a 
> bug in Acrobat?!
> The signature is there but Acrobat tools do not show it :(
> 
> Andreas
> 
> Paulo Soares schrieb:
> 
> >This is really strange. The signature is in the PDF but 
> after reading it
> >with Acrobat the signature disappears from the doc, no trace 
> of it. I'll
> >need to think a bit more about this.
> >
> >Paulo 
> >
> >  
> >
> >>-----Original Message-----
> >>From: [EMAIL PROTECTED] 
> >>[mailto:[EMAIL PROTECTED] On 
> >>Behalf Of Andreas Homrighausen
> >>Sent: Friday, April 28, 2006 12:54 PM
> >>To: [email protected]
> >>Cc: [EMAIL PROTECTED]
> >>Subject: Re: [iText-questions] Signing pdf documents 
> >>containing forms does not work-Sorry First one without content?!
> >>
> >>Thank you very much! :-)
> >>Attached you find four pdf-Files:
> >>Empty page, signed empty page, page with one form and this 
> >>one signed...
> >>
> >>Andreas
> >>
> >>Paulo Soares schrieb:
> >>
> >>    
> >>
> >>>It would help to post the original pdf, the pdf with the 
> form and the
> >>>signed pdf.
> >>>
> >>>Paulo 
> >>>
> >>> 
> >>>
> >>>      
> >>>
> >>>>-----Original Message-----
> >>>>From: [EMAIL PROTECTED] 
> >>>>[mailto:[EMAIL PROTECTED] On 
> >>>>Behalf Of [EMAIL PROTECTED]
> >>>>Sent: Friday, April 28, 2006 11:57 AM
> >>>>To: [email protected]
> >>>>Cc: [EMAIL PROTECTED]
> >>>>Subject: [iText-questions] Signing pdf documents containing 
> >>>>forms does not work-Sorry First one without content?!
> >>>>
> >>>>Hello all.
> >>>>
> >>>>I've written a java-method signing pdf-documents (which 
> are created
> >>>>by the tool scribus) using itext. With standard pdf documents 
> >>>>no problems... But if the scribus pdf contains only one form,
> >>>>something went wrong. The resulting signed pdf doesn't show the
> >>>>signature although it is in the "pdf-code" (Opened with 
> >>>>        
> >>>>
> >>word-pad ;-) )
> >>    
> >>
> >>>>Even using the setFormFlattening(true) does not help...
> >>>>Surprisingly the PDF-Analyzer 2.5 preview-mode shows the digital
> >>>>signature but all other tools don't.
> >>>>
> >>>>Here's the code:
> >>>>
> >>>>public static void signDocument(String zertifikat, String 
> >>>>passphrase, String
> >>>>inputFile, String outputFile, String reason, String location) {
> >>>>       
> >>>>       try {
> >>>>          KeyStore ks = KeyStore.getInstance("pkcs12");
> >>>>          ks.load(new FileInputStream(zertifikat), 
> >>>>passphrase.toCharArray());
> >>>>          String alias = (String)ks.aliases().nextElement();
> >>>>          PrivateKey key = (PrivateKey)ks.getKey(alias,
> >>>>passphrase.toCharArray());
> >>>>          Certificate[] chain = ks.getCertificateChain(alias);
> >>>>          PdfReader reader = new PdfReader(inputFile);
> >>>>          FileOutputStream fout = new 
> FileOutputStream(outputFile);
> >>>>          PdfStamper stp = 
> >>>>PdfStamper.createSignature(reader, fout, '');
> >>>>          PdfSignatureAppearance sap = 
> >>>>        
> >>>>
> >>stp.getSignatureAppearance();
> >>    
> >>
> >>>>          sap.setCrypto(key, chain, null,
> >>>>PdfSignatureAppearance.WINCER_SIGNED);
> >>>>          sap.setReason(reason);
> >>>>          sap.setLocation(location);
> >>>>          sap.setVisibleSignature(new 
> >>>>Rectangle(450,700,550,800), 1, null);
> >>>>          stp.close();
> >>>>           } catch (Exception e) {
> >>>>               System.out.println(e);
> >>>>           }
> >>>>   }
> >>>>
> >>>>Scribus -> new empty page -> pdf -> signing -> signed pdf 
> works fine
> >>>>Scribus -> new empty page -> Insert form -> pdf -> signing -> 
> >>>>signed pdf  does
> >>>>not work,
> >>>>same configurations...
> >>>>
> >>>>
> >>>>Any ideas?
> >>>>Thank you very much!
> >>>>
> >>>>Greetings from Ol' Germany,
> >>>>Andreas
> >>>>
> >>>>
> >>>>
> >>>>
> >>>>
> >>>>
> >>>>
> >>>>
> >>>>
> >>>>
> >>>>
> >>>>
> >>>>
> >>>>
> >>>>-------------------------------------------------------
> >>>>Using Tomcat but need to do more? Need to support web 
> >>>>services, security?
> >>>>Get stuff done quickly with pre-integrated technology to make 
> >>>>your job easier
> >>>>Download IBM WebSphere Application Server v.1.0.1 based on 
> >>>>Apache Geronimo
> >>>>http://sel.as-us.falkag.net/sel?cmd=k&kid0709&bid&3057&dat1642
> >>>>_______________________________________________
> >>>>iText-questions mailing list
> >>>>[email protected]
> >>>>https://lists.sourceforge.net/lists/listinfo/itext-questions
> >>>>
> >>>>   
> >>>>
> >>>>        
> >>>>
> >>>-------------------------------------------------------
> >>>Using Tomcat but need to do more? Need to support web 
> >>>      
> >>>
> >>services, security?
> >>    
> >>
> >>>Get stuff done quickly with pre-integrated technology to 
> >>>      
> >>>
> >>make your job easier
> >>    
> >>
> >>>Download IBM WebSphere Application Server v.1.0.1 based on 
> >>>      
> >>>
> >>Apache Geronimo
> >>    
> >>
> >>>http://sel.as-us.falkag.net/sel?cmd=k&kid0709&bid&3057&dat1642
> >>>_______________________________________________
> >>>iText-questions mailing list
> >>>[email protected]
> >>>https://lists.sourceforge.net/lists/listinfo/itext-questions
> >>> 
> >>>
> >>>      
> >>>
> >
> >
> >-------------------------------------------------------
> >Using Tomcat but need to do more? Need to support web 
> services, security?
> >Get stuff done quickly with pre-integrated technology to 
> make your job easier
> >Download IBM WebSphere Application Server v.1.0.1 based on 
> Apache Geronimo
> >http://sel.as-us.falkag.net/sel?cmd=k&kid0709&bid&3057&dat1642
> >_______________________________________________
> >iText-questions mailing list
> >[email protected]
> >https://lists.sourceforge.net/lists/listinfo/itext-questions
> >  
> >
> 
> 
> 
> -------------------------------------------------------
> Using Tomcat but need to do more? Need to support web 
> services, security?
> Get stuff done quickly with pre-integrated technology to make 
> your job easier
> Download IBM WebSphere Application Server v.1.0.1 based on 
> Apache Geronimo
> http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&;
> dat=121642
> _______________________________________________
> iText-questions mailing list
> [email protected]
> https://lists.sourceforge.net/lists/listinfo/itext-questions
> 


-------------------------------------------------------
Using Tomcat but need to do more? Need to support web services, security?
Get stuff done quickly with pre-integrated technology to make your job easier
Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
http://sel.as-us.falkag.net/sel?cmd=lnk&kid0709&bid&3057&dat1642
_______________________________________________
iText-questions mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/itext-questions

Reply via email to