RE: RSA_private_decrypt without e and d

2011-02-25 Thread Marek . Marcola
enssl-users@openssl.org > > To > > > > cc > > Subject > > RE: RSA_private_decrypt without e and d > > Hi Marek, > My understanding was that while it's mathematically possible, from an > OpenSSL API perspective there is no way to do it.

RE: RSA_private_decrypt without e and d

2011-02-24 Thread Shaheed Bacchus (sbacchus)
om.pl Sent: Thursday, February 24, 2011 11:23 AM To: openssl-users@openssl.org Cc: openssl-users@openssl.org; owner-openssl-us...@openssl.org Subject: RE: RSA_private_decrypt without e and d Hello, Remember, you do not need to recover this parameters to decrypt message. Best regards, -- Marek Ma

RE: RSA_private_decrypt without e and d

2011-02-24 Thread Marek . Marcola
1 05:21 PM > > Please respond to > openssl-users@openssl.org > > To > > > > cc > > Subject > > RE: RSA_private_decrypt without e and d > > Thanks Mounir and Marek, I will try to recover these parameters. > > -Original Message- > Fro

RE: RSA_private_decrypt without e and d

2011-02-24 Thread Shaheed Bacchus (sbacchus)
: RSA_private_decrypt without e and d Hi Shaheed, The OpenSSL error you are getting means that OpenSSL decrypted the ciphered text but couldn't find the PKCS1 padding byte. This means that the wrong CRT parameters were supplied. Usually this comes from the fact that the parameters p and q (an

Re: RSA_private_decrypt without e and d

2011-02-24 Thread Victor Duchovni
On Thu, Feb 24, 2011 at 08:15:47AM +0100, Mounir IDRASSI wrote: > Your analysis is not true because the original poster says he has dmp1, > dmq1 and iqmp, not only p and q. Yes, naturally if the OP has "d" (or equivalently d mod (p-1) and (q-1), which are presumed co-prime), he can recover "e" i

Re: RSA_private_decrypt without e and d

2011-02-23 Thread Mounir IDRASSI
Hi Shaheed, The OpenSSL error you are getting means that OpenSSL decrypted the ciphered text but couldn't find the PKCS1 padding byte. This means that the wrong CRT parameters were supplied. Usually this comes from the fact that the parameters p and q (and the corresponding dmp1, dmq1) must be

Re: RSA_private_decrypt without e and d

2011-02-23 Thread Mounir IDRASSI
Hi Victor, Your analysis is not true because the original poster says he has dmp1, dmq1 and iqmp, not only p and q. With these 5 parameters, it is possible to recover the plain text from the ciphered text thanks to the Chinese Reminder Transformation (CRT). Moreover, it is possible to recover

Re: RSA_private_decrypt without e and d

2011-02-23 Thread Marek . Marcola
Hello, Try to disable RSA blinding with: RSA_blinding_off(new_key); before RSA_private_decrypt(). Best regards, -- Marek Marcola owner-openssl-us...@openssl.org wrote on 02/24/2011 03:46:53 AM: > "Shaheed Bacchus (sbacchus)" > Sent by: owner-openssl-us...@openssl.org > > 02/24/2011 03

Re: RSA_private_decrypt without e and d

2011-02-23 Thread Marek . Marcola
gt; > 02/24/2011 05:50 AM > > Please respond to > openssl-users@openssl.org > > To > > openssl-users@openssl.org > > cc > > Subject > > Re: RSA_private_decrypt without e and d > > On Wed, Feb 23, 2011 at 09:03:13PM -0600, Shaheed Bacchus (sb

Re: RSA_private_decrypt without e and d

2011-02-23 Thread Victor Duchovni
On Wed, Feb 23, 2011 at 09:03:13PM -0600, Shaheed Bacchus (sbacchus) wrote: > Just to be clear, below is not the actual code, but what I would *like* > to be able to do (or something close). What you are asking to do is not possible, not because of API limitations, but as a matter of principle (m

RE: RSA_private_decrypt without e and d

2011-02-23 Thread Shaheed Bacchus (sbacchus)
Just to be clear, below is not the actual code, but what I would *like* to be able to do (or something close). From: owner-openssl-us...@openssl.org [mailto:owner-openssl-us...@openssl.org] On Behalf Of Shaheed Bacchus (sbacchus) Sent: Wednesday, February 23, 2011 9:47 PM To: openssl-users@open