3 Replies Latest reply on Apr 16, 2003 12:21 PM by tlamarca

    RMISecurityManager

    vtecinc Newbie

      Since this forum is called Security & JAAS I hope that I'm posting in the correct forum. If not, apologies and a redirect in a posted reply to the correct forum would be appreciated.

      I'm seeing the following error
      (no security manager: RMI class loader disabled)
      when I run an app on JBoss that ran fine in another container. The RMI server app and the client web app that calls to it were both compiled under JDK1.3, however, JBoss 3.04 is using JDK 1.4.1_01. Could this discrepancy cause the above error?

      As a result of the class loader being disabled, dynamic downloading of the stub is interrupted and a ClassNotFoundException results a little further down in the trace.

      Any insights into what might cause this would be most appreciated.

        • 1. Re: RMISecurityManager
          Lewis Henderson Novice

          You need to run with a security manager...

          Add
          -Djava.security.manager=java.rmi.RMISecurityManager
          -Djava.security.policy=/dir to policy file/java.policy

          to your application's command line

          The policy file should contain the required permissions for your application.


          Regards


          Lewis

          • 2. Re: RMISecurityManager
            vtecinc Newbie

            I appreciate the reply but don't know how to do this for a web application - this isn't a stand alone client with a command line. I've tried opening up the java.policy file and server.policy security to give all permissions but this seems to make no difference. Any further insights or info would be appreciated.

            Doug

            • 3. Re: RMISecurityManager
              tlamarca Newbie

              I don't know how clean this is, but if you need to add system properites like that at startup time you can do that for your web apps in jboss/bin/run.sh . You could also at run time call System.setProperty() (for setting the policy) and System.setSecurityManager() (for setting RMISecurityManager) in some startup block. If you are using JBoss 3, look for "# Setup JBoss sepecific properties" in run.sh and you will see where you can add system properties like the examples in the previous post.