<security-constraint>
<web-resource-collection>
<web-resource-name>Common pages</web-resource-name>
<url-pattern>/test1.html</url-pattern>
<http-method>GET</http-method>
</web-resource-collection>
<auth-constraint>
<role-name>MY_GROUP</role-name>
</auth-constraint>
</security-constraint>
as expected, with this constraint, the page /test1.html needs authentication, and the page /test2.html does not need authentication.
<security-constraint>
<web-resource-collection>
<web-resource-name>Common pages</web-resource-name>
<url-pattern>/*</url-pattern>
<http-method>GET</http-method>
</web-resource-collection>
<auth-constraint>
<role-name>MY_GROUP</role-name>
</auth-constraint>
</security-constraint>
as expected, with this constraint, all pages need authentication, including /test2.html.
<security-constraint>
<web-resource-collection>
<web-resource-name>Common pages</web-resource-name>
<url-pattern>/</url-pattern>
<url-pattern>/test1.html</url-pattern>
<http-method>GET</http-method>
</web-resource-collection>
<auth-constraint>
<role-name>MY_GROUP</role-name>
</auth-constraint>
</security-constraint>
with this constraint, I would expect that the page /test1.html and / need authentication, but the page /test2.html should not need authentication.
However, it turns out that /test2.html also requires authentication.
Question 1. Is that normal? Why is so?
Question 2. Where is it written in the specification that the url-pattern "/" is equivalent to "/*"? Java Servlet Specification 2.5: http://goo.gl/UxoPL
Question 3. How can I tell that the root page "/" requires authentication, but not the other pages?
ps: I am using jboss-eap-4.3.