policy file

D

Daniel

I have this in my policyfile
grant{
permission java.net.SocketPermission "localhost:1099", "connect, resolve";
permission java.net.SocketPermission "localhost:1024-", "connect, resolve";
permission java.net.SocketPermission "localhost:1024-", "accept, resolve";
permission java.net.SocketPermission "localhost:5432", "connect, resolve";

};
in dos.
H:\sapa>java -D java.security.policy=H:\sapa\local.policy -cp "H:\sapa\sapa"
RMIServer
Exception in thread "main" java.lang.NoClassDefFoundError:
java/security/policy=
H:\sapa\local/policy

I always get this error message, I dont understand. The classes are all in
h:\sapa\sapa and the policy file is in h:\sapa\
Why does the compiler never have mercy on me? I compiled the RMIServer
without problems. WHen i start the server it gives me an eroor:

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

My database runs under postgres, without the whole RMI statements the
application works, Why cant i set the policy file?

Thanks in advance
Danny
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,769
Messages
2,569,576
Members
45,054
Latest member
LucyCarper

Latest Threads

Top