title: Difficulties with basic Spring Security Configuration
body: <p>I'm trying to build a very basic, straight-forward authentication for a spring project.</p>
  
  <p>The problem I'm having is that the application constantly sends me to the "login-failed" page, although I've declared 2 basic accounts (admin and user).</p>
  
  <p>my application-Security.xml:</p>
  
  <pre><code>&lt;http auto-config="true" use-expressions="true"&gt;
          &lt;form-login login-processing-url="/resources/j_spring_security_check" login-page="/login" authentication-failure-url="/login/denied" /&gt;
          &lt;logout logout-url="/resources/j_spring_security_logout" /&gt;
          &lt;!-- Configure these elements to secure URIs in your application --&gt;
          &lt;intercept-url pattern="/choices/**" access="hasRole('ROLE_ADMIN')" /&gt;
          &lt;intercept-url pattern="/member/**" access="isAuthenticated()" /&gt;
          &lt;intercept-url pattern="/resources/**" access="permitAll" /&gt;
          &lt;intercept-url pattern="/login" access="permitAll" /&gt;
          &lt;intercept-url pattern="/home/**" access="hasRole('ROLE_ADMIN')" /&gt;
          &lt;intercept-url pattern="/*Details/*" access="hasRole('ROLE_USER')" /&gt;
  
      &lt;/http&gt;
      &lt;!-- Configure Authentication mechanism --&gt;
      &lt;authentication-manager alias="authenticationManager"&gt;
          &lt;!-- SHA-256 values can be produced using 'echo -n your_desired_password | sha256sum' (using normal *nix environments) --&gt;
          &lt;authentication-provider&gt;
              &lt;password-encoder hash="sha-256" /&gt;
              &lt;user-service&gt;
                  &lt;user name="admin" password="admin" authorities="ROLE_ADMIN" /&gt;
                  &lt;user name="user" password="user" authorities="ROLE_USER" /&gt;
              &lt;/user-service&gt;
          &lt;/authentication-provider&gt;
      &lt;/authentication-manager&gt;
  </code></pre>
  
  <p>my VERY basic login-form:</p>
  
  <pre><code>&lt;form action="/${app_name}/resources/j_spring_security_check" method="POST"&gt;
          &lt;label for="j_username"&gt;Username&lt;/label&gt;
          &lt;input id="j_username" name="j_username" type="text" /&gt;&lt;br/&gt;
  
          &lt;label for="j_password"&gt;Password&lt;/label&gt;
          &lt;input id="j_password" name="j_password" type="password" /&gt;&lt;br/&gt;
  
          &lt;input type="submit" value="Login" /&gt;
      &lt;/form&gt;
  </code></pre>
  
  <p>For now the controller is there only to resolve the URLs for login, login/denied etc.</p>
  
  <p>I'm just starting out with Spring and Roo, so this might just be something obvious that I'm overlooking.</p>
  
  <p>Thanks to anyone taking the time to answer.</p>