private void Application_OnPostAuthenticateRequest(object sender, EventArgs e) { IPrincipal currentPrincipal = HttpContext.Current.User; if (currentPrincipal.Identity.IsAuthenticated) { FormsIdentity formsIdentity = (FormsIdentity)currentPrincipal.Identity; DMSIdentity identity = new DMSIdentity(formsIdentity.Ticket); DMSPrincipal principal = new DMSPrincipal(identity); HttpContext.Current.User = principal; Thread.CurrentPrincipal = principal; } }
public DMSPrincipal(DMSIdentity identity) : base(identity, null) { }