i have loaded my java class which use the Sun JCE 1.2.2 to Oracle9i,
but it can be run.
the exception is:
java.lang.SecurityException: Cannot set up certs for trusted CAs: java.net.MalformedURLException: no protocol: US_export_policy.jar
I also did a test with JCE 1.2.1 ,thye error same as JCE1.2.2.
*** 2005-01-17 15:09:03.000
*** SESSION ID:(9.748) 2005-01-17 15:09:03.000
java.lang.SecurityException: Cannot set up certs for trusted CAs
I have a similar problem. I am trying to execute an HTTP post to a server protected by NTLM authentication from oracle 9i. I am using the Jakarta commons HTTP client (2.0.2) and the JCE 1.2.2. I had tested this outside Oracle with a sun jre 1.3.1_15 with no problems. When I execute my post it seems to be missing a class:
Please excuse me, but I am unfamiliar with JCE. However, I believe that the OracleJVM that comes with the Oracle 9i database is fully compliant with SUN's JDK version 1.3. Therefore, I imagine that the OracleJVM should support JCE. Unfortunately, there's not much more I can offer.
As Maciej mentioned, there is a "jdk/jre/lib/security/cacerts" subdirectory (under the "ORACLE_HOME" directory) -- but I don't know what you are meant to do with it.
It may be the cacerts file is not appropriate (I am no expert in JCE either), but I note that when I ran my application in the external sun JDK I did not have to add certificates (the JCE is used to create NTLM authentication credentials and I provide all the required information in the program code). Also, the cacerts file under my sun jre 1.3 seems to be very similar to the one stored under my oracle home (but they are not identifical to a binary diff).
I think that this is more likely a resource load problem, as the JCE has a plugable provider interface and is likely to make heavy use loading class files and other resources by name.
I don't really have time to investigate this further. I can work around the problem by using a different authentication scheme in my application. However, since the JCE is part of the Java 1.4 specification and this spec is used, I believe, in the Oracle 10g release and I will likely have an chance to look at running my code in 10g in the next few weeks, I will post a quick note to say if the same code works there or not.
To use the javax.crypto.* within my Java Stored Procedure on Oracle 9i, I had to load the jce1_2_2.jar as a resource, using the loadjava utility.
I am using DESede encryption type to encrypt/decrypt data on database, and therefore am using the Sun Provider. I also had to use loadjava to load the sunjce_provider.jar as a resource before I was able to compile my Java SP.