Quantcast
Channel: ASP.NET Core
Viewing all articles
Browse latest Browse all 9386

Cookie middleware in MVC 6

$
0
0

I am trying to understand the cookie Middleware authentication behavior and its flow. However, I am not able to understand that. Below is my issue

  1. Does cookie has to be set/get with ClaimsIdentity and not using asp.net identity ?
  2. I have implemented Remember Me functionality which creates the cookie, so in this I need to use Cookie middleware OR not ?, for this I am using below code

    var result = await _signInManager.PasswordSignInAsync(model.Email, model.Password, model.RememberMe, lockoutOnFailure: true);

    So,  considering the above way how can I validate the user based on cookie ? which is the preferred way for creating cookie 1 OR 2 point ?

  1. How can I validate user based on cookie using claims identity ?

Any help on this appreciated !


Viewing all articles
Browse latest Browse all 9386

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>