We are launching an applet using jnlp The applet needs to load a native library The jar and the jnlp are signed with a self generated certificate. The jnlp grants all permission with
<security>
<all-permissions/>
</security>
The policy file grants all permissions grant { permission java.security.AllPermission; };
We are getting a popup dialog “ java security warning” That says: this application is going to perform an insecure operation. Do you want to continue ?
Continue or cancel (see attached screen shot)
There is no “allow always” button
Which means that the dialog pops up “every time” the applet is launched. This is annoying to the user.
What can be done to disable this dialog to pop up or to make it appear at most once?
I had the following params and got the same problem:
Removing them solved it.
Use a certificate that has been verified by a trusted authority. Disabling/ignoring the 'always allow' field for self-signed certificates is a decision by Oracle that they are unlikely to change.
Using the remote debug parameters in JAVA_OPTS can cause this pop-up
-agentlib:jdwp=transport=dt_socket,address=localhost:8000,server=y,suspend=n
We had a problem with the JNLP arguments actually. You cannot specify any argument in the JNLP jre args parameter otherwise you'll get the security warning.
To avoid security warning popup use the properties and JVM arguments from the lists located from line 638: http://javasourcecode.org/html/open-source/jdk/jdk-6u23/com/sun/deploy/config/Config.java.html
On your JNLP, if the JVM arguments include something that is not listed in there, you will get the popup even if you properly sign the certificate. It all boils down to using 'secured' parameters + a proper certificate and it will be ok.
EDIT
The URL was removed so here are the valid arguments:
EDIT
At the time we had these arguments:
The problem was with -Djava.security.policy, and I couldn't understand the popup until I removed it from there.
NEW URL FOR java source jdk6.23