Win a copy of The Little Book of Impediments (e-book only) this week in the Agile and Other Processes forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Applets with JNI (urgent)

 
Sanket Bakshi
Greenhorn
Posts: 8
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
hi,
I am trying to write a applet which will call some native functions. I was succesful in writing a application or similar purpose.
In the applet, I have used a digitally signed appet.
This applet when executed in the browser, fails at the loadLibrary method giving a Security Exception.
I tried to modify the java.policy file but I cant get how to link it to my code or how to apply the permissions in my code. I granted a permission in the java.policy file based on a specific CODEBASE.
Can someone help me and tell how I can link this policy file to my code in the applet ?
The applet that I am using is digitally signed.
How do I set the permissions to the applet ?
Please help !
Urgent
 
maateen ashraf
Ranch Hand
Posts: 122
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
u have to write a security file & the allow permissions in it
to let ur applet to be run by browser.....
 
Sanket Bakshi
Greenhorn
Posts: 8
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Originally posted by maateen ashraf:
u have to write a security file & the allow permissions in it
to let ur applet to be run by browser.....

I tried to edit the java.policy file also added the grant clause based no CODEBASE. But I dont know how I can link the policy file to my applet.
Where will be the policy file be referenced ?
On many machines without JDK, I've seen that there is no such file with .policy extension. On these machines, how does my applet gets its policies ?
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic