[prev in list] [next in list] [prev in thread] [next in thread] 

List:       gcrypt-devel
Subject:    Re: RSA PKCS#1 signing: differs from OpenSSL's?
From:       Werner Koch <wk () gnupg ! org>
Date:       2007-12-06 7:01:56
Message-ID: 8763zc487v.fsf () wheatstone ! g10code ! de
[Download RAW message or body]

On Wed,  5 Dec 2007 21:50, simon@josefsson.org said:

> I had the same experience when porting libssh2 from OpenSSL to
> libgcrypt, and this caused quite some confusion and a long debugging
> session.

Frankly, I had the same problem several times.  I added a note to the
Libgcrypt manual which might help us in the future.

> PKCS#1 calls the first prime P and the second one Q, and uses
> coeff=p^{-1} mod q, which would suggest that libgcrypt got this
> backwards.

Libgcrypt stems from gpg and this implements OpenPG.  OpenPGP defines

       - MPI of RSA secret prime value p.
       - MPI of RSA secret prime value q (p < q).
       - MPI of u, the multiplicative inverse of p, mod q.

Thus Libgcrypt uses this definition.


Shalom-Salam,

   Werner



-- 
Die Gedanken sind frei.  Auschnahme regelt ein Bundeschgesetz.


_______________________________________________
Gcrypt-devel mailing list
Gcrypt-devel@gnupg.org
http://lists.gnupg.org/mailman/listinfo/gcrypt-devel
[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic