I have an internal web app being built in ASP.NET 4
. We are stuck with using an authentication API built by another team. If a user to the site is authenticated
You can try with something like this:
FormsAuthentication.SetAuthCookie(username, rememberMe);
to set the cookie for authenticated user, then just use the [Authorize]
attribute on the Controller or Action that need authentication.
Try googling on the subject for further info, you will find a lot of stuff on authentication and authorization in MVC.