3 Replies Latest reply on May 10, 2005 8:50 AM by Matthew Shalorne

    Where do properties files go?

    Matthew Shalorne Newbie

      I am using declarative security in my web app. I am able to identify a servlet and put a constraint on it so that I get my login form when I reference it. I am using

      org.jboss.security.auth.spi.UsersRolesLoginModule

      I've hunted all over the place go through all the documentation I can find - there is regular reference to users.properties and roles.properties but no indication of where they should be. I have tried packaging them in the classes directory in my war file but the login service (j_security_check) takes me to my form-error-page every time I try and login (it appears not to be able to get to the correct password in the users.properties). I would appreciate any help you could offer in this regard.

      Thx

      Matthew

        • 1. Re: Where do properties files go?
          Matthew Shalorne Newbie

          I have found a guide on a Scottish University site. They confirm that classes is the right directory in my war file. I have also tried using the conf directory for the users.properties and roles.properties, tried specifying my properties file names in login-config as well but no joy. I have tried using BASIC but again it doesn't recognise my password. Two and a half days of zero productivity and starting to give up hope - has anyone ever got org.jboss.security.auth.spi.UsersRolesLoginModule to work?!

          Matthew

          Surrey, England

          • 2. Re: Where do properties files go?
            Scott Stark Master

            A resource means visible to the thread context class loader of the UsersRolesLoginModule user. Use unique properties names to avoid finding the wrong properties file as is illustrated by the jmx-console config:

             <application-policy name = "jmx-console">
             <authentication>
             <login-module code="org.jboss.security.auth.spi.UsersRolesLoginModule"
             flag = "required">
             <module-option name="usersProperties">jmx-console-users.properties</module-option>
             <module-option name="rolesProperties">jmx-console-roles.properties</module-option>
             </login-module>
             </authentication>
             </application-policy>
            



            • 3. Re: Where do properties files go?
              Matthew Shalorne Newbie

              Excellent Scott - yes, that's what it was, works fine now - phew!

              Thx
              Matthew