Ejemplo n.º 1
0
 protected void Application_AuthenticateRequest(object sender, EventArgs e)
 {
     IPrincipal principal = HttpContext.Current.User;
     if (principal != null && principal.Identity.IsAuthenticated && principal.Identity.AuthenticationType == "Forms")
     {
         //2. IDENTITY
         FormsIdentity fIndent = (FormsIdentity)principal.Identity;
         AOIdentity cIndent = new AOIdentity(fIndent.Ticket);
         AOPrincipal nPrincipal = new AOPrincipal(cIndent);
         HttpContext.Current.User = nPrincipal;
         Thread.CurrentPrincipal = nPrincipal;
     }
 }
Ejemplo n.º 2
0
 public AOPrincipal(AOIdentity cIndent)
 {
     this.Identity = cIndent;
 }