0
I started studying Asp.Net Core these days, I’m working with version 2.1. I can already log in and log out of the user, only I don’t know how to set his downtime.
I put this code, but after a few minutes it asks the login again
services.ConfigureApplicationCookie(options => {
options.LoginPath = PathString.FromUriComponent("/Account/Login");
options.ExpireTimeSpan = TimeSpan.FromHours(24);
});
Compared to real systems, I look for something like Facebook does, where you log in 1 time, and if you log in regularly it does not ask login.
What should I set up to do this?
From now on, thank you for your attention.
Identity? which version of . net core?
– Leandro Angelo
Version 2.1
<TargetFramework>netcoreapp2.1</TargetFramework>
– Fábio Lima
Yes, I am using Identity with my custom classes, because I use an existing database
– Fábio Lima