Skip to Main Content

Java Security

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

Encryption in a java web start application

843810Apr 10 2002 — edited Apr 10 2002
hi everybody,

I wrote an application launched by Java Web Start.
This application encrypt data on the client side and POST them to the server.
To encrypt I use JCE packages including sunjce_provider.jar, jce1_2_1.jar and
local_policy.jar and US_export_policy.jar.
local_policy.jar and US_export_policy.jar are not packages, each of them contains
a policy file.

When I test encryption on local no problem, but when I test with Java Web Start
I've got this exception :

java.lang.ExceptionInInitializerError:
java.lang.SecurityException: Cannot set up certs for trusted CAs

It's because the application launched by Java Web Start doesn't find local_policy.jar
and US_export_policy.jar.
There's a problem in my JNLP file :

<jnlp spec="1.0+" href="http://myserver/sources/test.jnlp" codebase="http://myserver/sources">
<information>
<title>Java Web Start TEST</title>
<vendor>NLE Intech</vendor>
<description>cryptage then upload</description>
</information>
<security>
<all-permissions/>
</security>
<resources>
<j2se version="1.3" />
<jar href="sunjce_provider.jar" />
<jar href="jce1_2_1.jar" />
<jar href="local_policy.jar" />
<jar href="US_export_policy.jar" />
</resources>
<application-desc main-class="HelloWorldSwing" >
<argument>c:\myfiletoencrypt</argument>
</application-desc>
</jnlp>

thank you for your answer
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on May 8 2002
Added on Apr 10 2002
1 comment
373 views