Uploaded image for project: 'Geronimo'
  1. Geronimo
  2. GERONIMO-5578

incorrect behaviour of security-constraint configuration in web.xml

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Major
    • Resolution: Fixed
    • 3.0.0
    • 2.1.7, 2.2.1, 3.0.0
    • Tomcat
    • Security Level: public (Regular issues)
    • None

    Description

      When have following configuration in web.xml, GET and POST can be accessed by both "RoleA" and "RoleB".

      <security-constraint>
      <web-resource-collection>
      <web-resource-name>resource2</web-resource-name>
      <url-pattern>/SampleServlet2</url-pattern>
      <http-method>GET</http-method>
      </web-resource-collection>
      <auth-constraint>
      <role-name>RoleA</role-name>
      </auth-constraint>
      </security-constraint>

      <security-constraint>
      <web-resource-collection>
      <web-resource-name>resource3</web-resource-name>
      <url-pattern>/SampleServlet2</url-pattern>
      <http-method>POST</http-method>
      </web-resource-collection>
      <auth-constraint>
      <role-name>RoleB</role-name>
      </auth-constraint>
      </security-constraint>

      Attachments

        1. GERONIMO-5578.patch
          10 kB
          Hong Fang Han
        2. web7.xml
          2 kB
          Hong Fang Han

        Activity

          People

            xuhaihong Haihong Xu
            hanhongfang Hong Fang Han
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: