aspose file tools*
The moose likes Developer Certification (SCJD/OCMJD) and the fly likes rmi security problem : policy file Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of EJB 3 in Action this week in the EJB and other Java EE Technologies forum!
JavaRanch » Java Forums » Certification » Developer Certification (SCJD/OCMJD)
Bookmark "rmi security problem : policy file" Watch "rmi security problem : policy file" New topic
Author

rmi security problem : policy file

Michael Tu
Greenhorn

Joined: Oct 14, 2002
Posts: 29
Have to bring myself here as the problem makes me crazy

I created a security manager in my RMI server simply use:
System.setSecurityManager(new RMISecurityManager());

Also, I have a fbn.policy file like:
grant {
permission java.security.AllPermission;
};

then I start my RMI server by specifying -Djava.security.policy=c:\...\fbn.policy. The server runs OK.
Now, my client side also has a line of:
System.setSecurityManager(new RMISecurityManager());

I run my client in the same PC with -Djava.security.policy=c:\...\fbn.policy. It doesn't work! Connection error comes out.
If I do not implement SecurityManager, everything is fine. What's the hell for this? Can anyone advise? Thanks.
Michael
John Smith
Ranch Hand

Joined: Oct 08, 2001
Posts: 2937

I run my client in the same PC with -Djava.security.policy=c:\...\fbn.policy. It doesn't work! Connection error comes out.
If I do not implement SecurityManager, everything is fine. What's the hell for this? Can anyone advise? Thanks.

The consensus in this group is that you should not use policy files, security managers, codebase or classpath settings, or dynamic downloading. These are the "extra features" that do not add much to your design, but they complicate things greatly for you and your accessor.
Eugene.
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: rmi security problem : policy file
 
Similar Threads
RMI Explanation
Cannot bind on Windows 95
SecurityManager confusion - RMI
dear friends - can you please help me
RMI security issue in websphere