Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
Home -> Community -> Usenet -> c.d.o.misc -> oracle 10g cryptography problem
Hi,
I have a java stored procedure for oracle 10g (running jdk1.4) that uses the javax.crypto package and the bouncy castle provider for RSA decryption. Here is a snippet of the code in the procedure:
Security.addProvider(new
org.bouncycastle.jce.provider.BouncyCastleProvider());
Cipher rsaCipher = Cipher.getInstance("RSA");
RSAPrivateKey key = (RSAPrivateKey)
MSPrivKeytoJKey.getPrivateKey(aKey);
rsaCipher.init(Cipher.DECRYPT_MODE, key);
rsaCipher.doFinal(encryptedByteArray);
This works fine on my own machine running jdk1.4. However, when I load my stored procedure into the database and run it, I get the following exception after the line
Cipher rsaCipher = Cipher.getInstance("RSA");
tries to execute:
java.security.NoSuchAlgorithmException: Cannot find any provider supporting RSA
I have tried the following (based on information gathered from various forums):
but i still get the same error.
I am reaching out desperately to all you experts for help :)
Pouria Received on Tue Jun 26 2007 - 12:47:27 CDT