title: ADFSv2.1 with aspnet mvc 5 redirect loop
body: <p>I'm setting up a development environment to test out the ADFS login mechanism.</p>
  
  <p>I have access to the admin of the ADFS server, and to my knoledge, everything is correctly configured (of course, my knoledge in the subject is very limited).</p>
  
  <p>When I create a new mvc5 web site, I point the metadata URL and the identifier and everything gets generated correclty, but when I launch the site, after entering valid credentials, the browser enters in a 302 redirect loop.</p>
  
  <p>I already did extensive searches on the interweb for solutions and guidance, but the server setup seems ok and I don't touch anything that the mvc project wizard generates for me.</p>
  
  <p>My MVC5 Site is created with this options: <a href="http://www.asp.net/visual-studio/overview/2013/creating-web-projects-in-visual-studio#orgauthonprem" rel="nofollow">http://www.asp.net/visual-studio/overview/2013/creating-web-projects-in-visual-studio#orgauthonprem</a></p>
  
  <p>And for the server configuration, I'm following this guide: <a href="http://www.syfuhs.net/post/2010/08/13/Installing-ADFS-2-and-Federating-an-Application.aspx" rel="nofollow">http://www.syfuhs.net/post/2010/08/13/Installing-ADFS-2-and-Federating-an-Application.aspx</a> up until the part when they create the web site, of course.</p>
  
  <p>Any help will be appreciated </p>
  
  <p>NOTE: Using ADFS v2.1 on Server 2012</p>