title: Multiple <http> tags with same authentication manager in Spring Security 3.1
body: <p>I am using Spring Security 3.1.2
  This version allows multiple "http" tags.</p>
  
  <p>I have an application that has two separate login pages, one for user and another for admin. Both of them will use the same authentication manager.</p>
  
  <p>I have build my spring-security.xml in the following manner</p>
  
  <pre><code>&lt;sec:http pattern="/loginForm.jsp" security="none"/&gt;
              &lt;sec:http pattern="/loginForm2.jsp" security="none"/&gt;
              &lt;sec:http auto-config="true"&gt;
                  &lt;sec:intercept-url pattern="/login1*" access="ROLE_USER" /&gt;
                  &lt;sec:form-login login-page="/loginForm.jsp" default-target-url="/login1"
                      authentication-failure-url="/loginForm.jsp?login_error=1" /&gt;
                  &lt;sec:logout logout-success-url="/loginForm.jsp" /&gt;
              &lt;/sec:http&gt;
  
              &lt;sec:http auto-config="true"&gt;
                  &lt;sec:intercept-url pattern="/login2*" access="ROLE_ADMIN" /&gt;
                  &lt;sec:form-login login-page="/loginForm2.jsp" default-target-url="/login2"
                      authentication-failure-url="/loginForm2.jsp?login_error=1" /&gt;
                  &lt;sec:logout logout-success-url="/loginForm2.jsp" /&gt;
              &lt;/sec:http&gt;
  
  
  
  &lt;sec:authentication-manager&gt;
                 &lt;sec:authentication-provider&gt;
                     &lt;sec:user-service&gt;
                           &lt;sec:user name="qwertyui" password="123456" authorities="ROLE_USER" /&gt;
                           &lt;sec:user name="asdfghjk" password="123456" authorities="ROLE_USER" /&gt;
                     &lt;/sec:user-service&gt;
                 &lt;/sec:authentication-provider&gt;
  
              &lt;/sec:authentication-manager&gt;
  </code></pre>
  
  <p>But I am getting this error "A universal match pattern ('/**') is defined  before other patterns in the filter chain, causing them to be ignored. Please check the ordering in your  namespace or FilterChainProxy bean configuration"</p>
  
  <p>If I omit any one of the  tag, it works fine.</p>