Hi ,
I am using Owin Authentication. I want my application to redirect to login page after specified time. So i have set the expiration time in CookieAuthenticationOptions.
Here is my code.
app.SetDefaultSignInAsAuthenticationType(CookieAuthenticationDefaults.AuthenticationType);
app.UseCookieAuthentication(new CookieAuthenticationOptions
{
ExpireTimeSpan = TimeSpan.FromMinutes(2.0),
SlidingExpiration = false
});
I am able to browse through the application even after 2 mins of login and no login page redirection is seen .
My code is similar to the thread "OWIN Authentication and timeout with redirection". I have tried the fix in this thread but it didn't work.