On 25/09/2012 11:13, sanduche wrote:
> I would like to sign pdf using iTextSharp and smart card.
> PrivateKeySignature constructor requires
> Org.BouncyCastle.Crypto.IICipherParameters object but I don't know how to
> create it from X509Certificate2.PrivateKey. I found examples which are using
> BC and PKCS12/DotNet for converting but none with PKCS11 (or just using
> standard .NET libraries).
Please read http://itextpdf.com/book/digitalsignatures
It explains how to sign documents using a smart card in three different 
ways:
- using MSCAPI: it should be easy to adapt this to C# as this is a pure 
Windows solution.
- using PKCS#11: do you have the correct DLL to do this?
- using javax.smartcardio: not an option for you as this is a pure Java 
solution.

We've discovered even a fourth way: using a special key store instance 
if the smart card provider allows this (by providing a library similar 
to BouncyCastle).

------------------------------------------------------------------------------
Live Security Virtual Conference
Exclusive live event will cover all the ways today's security and 
threat landscape has changed and how IT managers can respond. Discussions 
will include endpoint security, mobile security and the latest in malware 
threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/
_______________________________________________
iText-questions mailing list
[email protected]
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