2 Replies Latest reply on Jul 23, 2010 6:49 AM by Javier M

    HTTP Status 403

    Javier M Newbie

      When i try to access to my jmx-console I get the next message

       

      HTTP Status 403 - Access to the requested resource has been denied

       

      I already have checked

      $JBOSS_HOME/server/$CONFIG/deploy/jmxconsole.war/WEBINF/web.xml

      $JBOSS_HOME/server/<configuration>/conf/props/jmx-console-users.properties

       

      Does someone know what I'm doing wrong?

        • 1. Re: HTTP Status 403
          jaikiran pai Master

          Which AS version is this? And have you changed any configs? By default, the jmx-console doesn't require authentication. What does the jboss-web.xml file of jmx-console.war contain?

          • 2. Re: HTTP Status 403
            Javier M Newbie

            Im using JBoss EAP 5.0.1

             

            * My /home/myHome/jboss-eap-5.0/jboss-as/server/default/deploy/jmx-console.war/WEB-INF/web.xml

            <!-- A security constraint that restricts access to the HTML JMX console
               to users with the role JBossAdmin. Edit the roles to what you want and
               uncomment the WEB-INF/jboss-web.xml/security-domain element to enable
               secured access to the HTML JMX console.
               -->

             

               <security-constraint>
                 <web-resource-collection>
                   <web-resource-name>HtmlAdaptor</web-resource-name>
                   <description>An example security config that only allows users with the
                     role JBossAdmin to access the HTML JMX console web application
                   </description>
                   <url-pattern>/*</url-pattern>
                   <http-method>GET</http-method>
                   <http-method>POST</http-method>
                 </web-resource-collection>
                 <auth-constraint>
                   <role-name>JBossAdmin</role-name>
                 </auth-constraint>
               </security-constraint>

             

               <login-config>
                  <auth-method>BASIC</auth-method>
                  <realm-name>JBoss JMX Console</realm-name>
               </login-config>

             

               <security-role>
                  <role-name>JBossAdmin</role-name>
               </security-role>

             

            </web-app>

             

             

            * My jboss-eap-5.0/jboss-as/server/default/deploy/jmx-console.war/WEB-INF/web.xml

            <!DOCTYPE jboss-web PUBLIC
               "-//JBoss//DTD Web Application 5.0//EN"
               "http://www.jboss.org/j2ee/dtd/jboss-web_5_0.dtd">
              
            <jboss-web>
               <!-- Uncomment the security-domain to enable security. You will
                  need to edit the htmladaptor login configuration to setup the
                  login modules used to authentication users.
               -->
                  <security-domain>java:/jaas/jmx-console</security-domain>
            </jboss-web>

             

             

            * My /home/myHome/jboss-eap-5.0/jboss-as/server/default/conf/props/jmx-console-roles.properties

            # A sample roles.properties file for use with the UsersRolesLoginModule
            myUser=JBossAdmin,HttpInvoker

             

             

            * My /home/myHome/jboss-eap-5.0/jboss-as/server/default/conf/props/jmx-console-users.properties

            # A sample users.properties file for use with the UsersRolesLoginModule
            myUser=admin