2 Replies Latest reply on Dec 23, 2002 11:52 AM by annapurna

    Unable to find LoginModule-JBoss3.0.3 and Tomcat seperate

    annapurna Newbie


      I am trying to run JBoss3.0.3 and Tomcat4.0.5 seperately.When I am running a java client from the command line everything works fine. When I am trying to run from my HTML/Structs client through Tomcat I get an exception *UNABLE TO FIND LOGINMODULE* . It is able to locate the auth.conf file.

      Can someone help me out .
      Thanks in advance


        • 1. Re: Unable to find LoginModule-JBoss3.0.3 and Tomcat seperat
          rajiv mahal Newbie

          Could you please send me your ear/war app cause I'm very interested in setting up a similar test. Can you also indicate what changes you have made to tomcat and jboss to get them running.

          • 2. Re: Unable to find LoginModule-JBoss3.0.3 and Tomcat seperat
            annapurna Newbie


            I only change I made is in my client file which first creates a session with jboss server. I added these couple of lines.

            // must fetch these JNDI env
            AppCallbackHandler handler = new AppCallbackHandler(login, password.toCharArray());

            //a default login module in jboss
            LoginContext lc = new LoginContext("client-login", handler);

            I added auth.conf file as a system property with System.getProperty() method before I called these statements.

            The auth.conf should like like this

            // This file is now obsolete but is read for backward compatability
            // Use the login-config.xml file instead
            // $Id: auth.conf,v 1.1 2002/12/18 22:07:21 abikkina Exp $

            simple {
            // Very simple login module:
            // any user name is accepted.
            // password should either coincide with user name or be null,
            // all users have role "guest",
            // users with non-null password also have role "user"
            org.jboss.security.auth.spi.SimpleServerLoginModule required;

            // The default client login module configuration that infects the
            // EJB transport layer with the application caller
            other {

            // JBoss LoginModule
            org.jboss.security.ClientLoginModule required
            // Put your login modules that need JBoss here

            Also added jbosssx.jar to the classpath of tomcat startup.

            It works!