'Login as another user' MVC 4 Windows Authentication
I have an intranet project written in MVC 4 which uses Windows Authentication to authorise and authenticate users. I need to add a 'Login as another user' functionality. After some searching I found this solution which suggests returning a 401, and created the following Action (which is called using a form): // // POST: /Home/LogOut [HttpPost] [ValidateAntiForgeryToken] public ActionResult LogOut() { return new HttpUnauthorizedResult(); } The Action gets called, and the browser pops up a username and password window, however as the result redirects back to the Action, a 401 is always returned.