Beispiel #1
0
 private void CheckForFormsLogin(HttpContext ctx)
 {
     if (ctx.User == null ||
         ctx.User.Identity == null ||
         !ctx.User.Identity.IsAuthenticated)
     {
         var formsUsername = ClaimsCookieHelper.ExtractUsernameFromFormsCookie();
         if (!String.IsNullOrWhiteSpace(formsUsername))
         {
             var claims = cookieHelper.Read(ctx);
             cookieHelper.Write(ctx, formsUsername, claims);
         }
     }
 }