We have a large, distributed, legacy application that uses RMI. This code always checks System.getSecurityManager() and sets it to a new RMISecurityManager() if the system one is null.
Now, we've rewritten some of the legacy guis to utilize some J2EE components, but they still rely on some legacy RMI stuff.
Here's the scenario. We open the app and start communicating with JBoss. Everything is fine. Then the user does some stuff that needs to use the legacy RMI code. This code checks and finds out that there is no Security Manager, so it sets the security manager to a new RMISecurityManager. It does it's RMI thing and everything is happy. Then, the user does something that requires an interaction with JBoss and the JBoss code throws a SecurityException.
1. How/Why is System.getSecurityManager() null in the first place?
2. How do I get the code to work with legacy RMI stuff and with JBoss?
3. What security manager do I use?
I have the same problem. Somebody please help.