jboss 4: enable UsersRolesLoginModule, where must users.properties files be placed?

7,415

As I know there is 2 places where you can put these files:

  1. In conf dir, and then you reference to them by:

    <module-option name="usersProperties">props/jmx-console-users.properties<module-option>

  2. You can put these file in WEB-INF/classess dir and reference to them just by name:

    <module-option name="usersProperties">web-console-users.properties</module-option>

You can find these in web-console definition. The file with user names is located under: ./deploy/management/console-mgr.sar/web-console.war/WEB-INF/classes/web-console-users.properties

Share:
7,415

Related videos on Youtube

colin chen
Author by

colin chen

I'm a Unix/Linux sysadmin, my favourite server OSes are Solaris and Red Hat (RHEL/Centos).

Updated on September 17, 2022

Comments

  • colin chen
    colin chen over 1 year

    I have an application (CQ5) that requires enabling unauthenticatedIdentity on jbossdir/conf/login-config.xml I used:

       <authentication>
          <login-module code = "org.jboss.security.auth.spi.UsersRolesLoginModule"
             flag = "required" >
          <module-option name="unauthenticatedIdentity">nobody</module-option>
        </login-module>
       </authentication>
    

    then I tried to copy jbossdir/conf/props/jmx-console-users.properties,jmx-console-roles.properties into users.properties and roles.properies (same dir).

    I still get this error:

    ERROR [org.jboss.security.auth.spi.UsersRolesLoginModule] Failed to load users/passwords/role files java.io.IOException: No properties file: users.properties or defaults: defaultUsers.properties found

    where should I put those files?

    • colin chen
      colin chen over 14 years
      It looks like a workaround was commenting out the whole section, I still do not fully understand what's behind it, does anyone know any good resource on jboss authentication?
    • BoyMars
      BoyMars almost 13 years
      I found this useful: edc4it.com/2011/05/09/… (3 parts).