Thank you for the answers from everobody!

@Paulo: The code example is great but at the "sap.SetCrypto(null, chain,
null, null);" calling the chain parameter is an
Org.BouncyCastle.X509.X509Certificate[] and I would not like to use Bouncy
Castle classes.

@Andreas: I would not like to sign my pdf externally the web service is not
a solution for me.

@All: .NET 1.1 standard classes support the digital signature. (see:
http://msdn.microsoft.com/en-us/library/system.security.cryptography.rsacryptoserviceprovider(VS.71).aspx
)

So I had a hash from the pdf (also created by standard .net classes SHA256)
and I have already signed this hash used 
System.Security.Cryptography.RSACryptoServiceProvider .net class.

I have an encrypted byte[]. The question is that, how can I insert it by
IText to get the folowing result:

3 0 obj<</Rect[0 0 0 0]/AP<</N 2 0 R>>/P 4 0 R/FT/Sig/F
132/DR<<>>/Subtype/Widget/V 1 0 R/Type/Annot/T(Signature1)>>
endobj
1 0 obj<</ByteRange [0 295 12297 10992 ]                                        
                   
/Filter/Adobe.PPKMS/M(D:20090924165120+02'00')/Contents
<308006092a864886f...0000>/Name( bla-bal signature
name)/SubFilter/adbe.pkcs7.sha1/Type/Sig>>
endobj


Bests,

Tamas






Andreas Kuehne-2 wrote:
> 
> Hi Tamas,
> 
> 
> the bouncy castle components do most of the crypto processing required to
> build the signature. iText does many good things, but doesn't supply
> crypto functions on its own.
> Maybe you think about using a central service for signing. So you doesn't
> have to bother with crypto stuff in your app. You just have to call a web
> service.
> The OASIS DSS-X group defined an interface for PDF signing. And the
> forthcoming version of our open sourced signing servers supports this
> function.
> 
> Greetings
> 
> Andreas  
> 
> 
> ----- Original Message ----
> From: Tamas <info...@gmail.com>
> To: itext-questions@lists.sourceforge.net
> Sent: Monday, October 5, 2009 4:35:22 PM
> Subject: Re: [iText-questions] Creating PDF Digital signature without
> Bouncy Castle
> 
> 
> Thank you for the reply, but my aim is to sign a pdf using only .net and
> itext classes. Without Bouncy Castle.
> 
> 
> Mirco Piccin wrote:
>> 
>> Hi,
>> 
>>> I would like to put a digital signature to an existing PDF document. In
>> all
>>> of the IText documentation I found a desctiprion about how to sign a PDF
>> and
>>> all of the ways use Bouncy Castle classes to encrypt the document hash.
>> 
>> few months ago i do something similar.
>> I've used :
>> bcmail
>> bcprov
>> bctsp
>> Bouncy Castle libraries.
>> 
>> Here you can find a useful example:
>> http://www.mail-archive.com/itext-questions@lists.sourceforge.net/msg40287.html
>> 
>> Hope this helps you
>> Regards
>> M
>> 
>> ------------------------------------------------------------------------------
>> Come build with us! The BlackBerry&reg; Developer Conference in SF, CA
>> is the only developer event you need to attend this year. Jumpstart your
>> developing skills, take BlackBerry mobile applications to market and stay 
>> ahead of the curve. Join us from November 9-12, 2009. Register
>> now!
>> http://p.sf.net/sfu/devconf
>> _______________________________________________
>> iText-questions mailing list
>> iText-questions@lists.sourceforge.net
>> https://lists.sourceforge.net/lists/listinfo/itext-questions
>> 
>> Buy the iText book: http://www.1t3xt.com/docs/book.php
>> 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/
>> 
> 
> -- 
> View this message in context:
> http://www.nabble.com/Creating-PDF-Digital-signature-without-Bouncy-Castle-tp25749212p25751965.html
> Sent from the iText - General mailing list archive at Nabble.com.
> 
> 
> ------------------------------------------------------------------------------
> Come build with us! The BlackBerry&reg; Developer Conference in SF, CA
> is the only developer event you need to attend this year. Jumpstart your
> developing skills, take BlackBerry mobile applications to market and stay 
> ahead of the curve. Join us from November 9-12, 2009. Register now!
> http://p.sf.net/sfu/devconf
> _______________________________________________
> iText-questions mailing list
> iText-questions@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/itext-questions
> 
> Buy the iText book: http://www.1t3xt.com/docs/book.php
> 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/
> 
> 
> ------------------------------------------------------------------------------
> Come build with us! The BlackBerry&reg; Developer Conference in SF, CA
> is the only developer event you need to attend this year. Jumpstart your
> developing skills, take BlackBerry mobile applications to market and stay 
> ahead of the curve. Join us from November 9&#45;12, 2009. Register
> now&#33;
> http://p.sf.net/sfu/devconf
> _______________________________________________
> iText-questions mailing list
> iText-questions@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/itext-questions
> 
> Buy the iText book: http://www.1t3xt.com/docs/book.php
> 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/
> 
> 

-- 
View this message in context: 
http://www.nabble.com/Creating-PDF-Digital-signature-without-Bouncy-Castle-tp25749212p25767812.html
Sent from the iText - General mailing list archive at Nabble.com.


------------------------------------------------------------------------------
Come build with us! The BlackBerry&reg; Developer Conference in SF, CA
is the only developer event you need to attend this year. Jumpstart your
developing skills, take BlackBerry mobile applications to market and stay 
ahead of the curve. Join us from November 9&#45;12, 2009. Register now&#33;
http://p.sf.net/sfu/devconf
_______________________________________________
iText-questions mailing list
iText-questions@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/itext-questions

Buy the iText book: http://www.1t3xt.com/docs/book.php
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/

Reply via email to