Click to See Complete Forum and Search --> : Applets with JNI


Sanket Bakshi
May 12th, 2001, 02:29 AM
I want to carry out my JNI calls thru my applet. For this purpose, I am using a signed applet to make these calls. While running the Applet in Internet Explorer, it gives a SecurityException while trying to load a native library. The loadLibrary function fails while checking for permissions.
I tried editing the policy settings in the java.policy file. Can anybody let me know as to how I link the policy file with my actual code ?
Where is the poliy file refered from. As I have seen on machines without JDK installed that these machines do not have a .policy file on them. How can the applet get required policies on these machines ?
I want to know as to how I can link my policy file with my applet and when does the policy file gets referenced.

Norm
May 12th, 2001, 12:09 PM
My experience giving applets permissions has required that the applet be run using the Java plugin. This requires that the HTML be converted. Sun has an HTMLConversion program that you can download.
The Sun site has a tutorial on Security that used to be at:
http://java.sun.com/docs/books/tutorial/security/1.2/index.html

Norm