0 Replies Latest reply on Mar 23, 2003 5:38 PM by Thomas

    DatabaseServerLoginModule for use in jmx-console

    Thomas Newbie

      After working through a number of stupid problems (classpath, sql errors...) I believe I have MySql datasource setup correctly. There are no errors that I can find with the log4j level set to DEBUG on my
      jboss-3.0.4_tomcat-4.1.12 server. I made the changes to my login-config.xml below. I get the username password request when I hit my jmx-console page, but even though I am putting in a username and password that is in the webusers table, I always get an "Access to the requested resource denied..." error. I do not know how to further troubleshoot the problem because there are no errors. The password is in the database cleartext. Any suggestions would be appreciated.

      Thanks,
      Tom



      <application-policy name = "jmx-console">
      <!--authentication>
      <login-module code="org.jboss.security.auth.spi.UsersRolesLoginModule"
      flag = "required" />
      </authentication-->

      <login-module code = "org.jboss.security.auth.spi.DatabaseServerLoginModule"
      flag = "required">
      <module-option name = "dsJndiName">java:/MySqlDS</module-option>
      <module-option name = "principalsQuery">SELECT WebPassword FROM webusers WHERE WebUserName=?</module-option>
      <module-option name = "rolesQuery">SELECT RoleId, 'Roles' FROM UserRoles WHERE WebUserName=?</module-option>
      </login-module>

      </application-policy>