Max,

madmax wrote
> 1) removed the date stamps from both the itext and CAPICOM

As mentioned before, thw two signing times are not a problem. The PDF
specification recommends not to use both in the same PDF signature but it
does not forbid it.

> 2) Also changed the  bDetached parameter value to "false"  as suggested by
> Michael  in the javascript
> 
> 3) I also noticed that I could avoid getting the digest from the PDF and
> just created a signature using the browser  and some dummy data that I
> could pass. Then I can send it to the server and injecting into the PDF.

I see you're playing around with the CAPICOM SignedData class. I would
suggest you try that in a more systematic manner. What you want (as long as
you use adbe.pkcs7.detached or ETSI.CAdES.detached signatures --- but these
are the recommended ones anyway) are CMS signature containers with a single
signature without encapsulated data; and you have to be able to inject the
already calculated hash which in case of the presence of signed attributes
is to be used as MessageDigest attribute value.

Studying aszomor's code might present an alternative approach.

> BTW, what tools do you guys use to debug the PDF generation with itext?
> just the regular Eclipse debugger?

As long as signature container are created (i.e. the problem is not an early
exception) and merely not accepted by the Adobe Reader or some other
relevant verification software, the most important step of my first analysis
is creating an ASN.1 structure dump of the signature container and
inspecting it with the relevant specifications at hand. The outcome thereof
generally makes it quite clear where to look.

Regards,   Michael

--
View this message in context: 
http://itext-general.2136553.n4.nabble.com/Sign-and-PDF-with-SmartCard-and-web-browser-only-tp4319344p4372330.html
Sent from the iText - General mailing list archive at Nabble.com.

------------------------------------------------------------------------------
Virtualization & Cloud Management Using Capacity Planning
Cloud computing makes use of virtualization - but cloud computing 
also focuses on allowing computing to be delivered as a service.
http://www.accelacomm.com/jaw/sfnl/114/51521223/
_______________________________________________
iText-questions mailing list
iText-questions@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/itext-questions

iText(R) is a registered trademark of 1T3XT BVBA.
Many questions posted to this list can (and will) be answered with a reference 
to the iText book: http://www.itextpdf.com/book/
Please check the keywords list before you ask for examples: 
http://itextpdf.com/themes/keywords.php

Reply via email to