tags:

views:

878

answers:

2

hi, I am using RSA modulus and encrypting a data with modulus and trying to decrypt it with private key of RSA ..i m using RSA/ECB/PKCS1Padding at the decrypt end

Thnx in advance

+1  A: 

You can probably use the Bouncy Castle lightweight cryptography API to do your decryption.

Note that RSA cryptography may be illegal to import into some countries.

Zarkonnen
The U.S. export restrictions on cryptography were relaxed in 2000. We still can't export without a license to foreign governments or to embargoed nations (but that last applies to just about anything, not just crypto). http://www.rsa.com/rsalabs/node.asp?id=2327
Bill the Lizard
...I realize that our laws don't apply to the rest of the world, so check the laws of your home country and the laws of the country you're exporting to. :)
Bill the Lizard
The Legion of the Bouncy Castle is Australian so US export law really doesn't apply.
Zarkonnen
A: 

hi, My question is if i am using RSA as an argument to Cipher.getInstance method while encryption and while i am decrypting it with RSA with the RSA/ECB/PKCS1Padding as an argument i am getting bad padding exception . If i am using RSA only in both the case it is woring fine but getting some random output not the original string ... which padding should i use ? Thnx in advance

Sam97305421562