In my case I wanted to debug a ASP .NET MVC application, that used Windows authentication, but my account was not added to the "Administrators" role in development. If you still want to debug the site as an Administrator you can set the role of the authenticated user in the Global.asax.

protected void Application_AuthenticateRequest(Object sender, EventArgs e)
{
    if (Context.User != null)
    {
        var userPrincipal = new GenericPrincipal(Context.User.Identity, new string[] { "Adminstrators" });
        Context.User = userPrincipal;
    } 
}

Leave a Reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.