Where to place java applet policy file?

Posted by makdere on Stack Overflow See other posts from Stack Overflow or by makdere
Published on 2010-04-10T09:36:58Z Indexed on 2010/04/10 9:43 UTC
Read the original article Hit count: 305

Filed under:
|
|

Hi all,

I am working on an artificial intelligence project which is a logic game and aims two user connecting to the server on the network who acts as an Admin and then start to play one by one.

In order to create connections, i have a server code which is just listening on localhost:8000 and assigning team values to the clients as they arrive. After connecting, clients make their move under Admin's control.

The question is that when i try to put my code to work in the browser it fails with the following error:

java.security.AccessControlException: access denied (java.net.SocketPermission 127.0.0.1:8000 connect,resolve)

Even though i have created my own policy, first granting only Socket access permission to the codebase of my project folder (file:///home/xxx/projects/-), after it didnt work i granted all permissions from all codebase. I tried placing my policy file both in the home directory and in the same directory where my applet code resides.

Appreciate any tips, thanks.

© Stack Overflow or respective owner

Related posts about java

Related posts about applet