I have found an MVC application at work with the following properties and there is something that smells bad to me. I do not finish understanding the timeouts of authentication
, sessionState
and ExpireTimeSpan
. Is it necessary to have all three? What differences are there between each one? I have searched for some information but I can not distinguish its uses.
<authentication mode="Forms">
<forms loginUrl="~/Auth/SignOn.aspx" timeout="40" slidingExpiration="true" />
</authentication>
<sessionState timeout="30" />
app.UseCookieAuthentication(new CookieAuthenticationOptions
{
AuthenticationType = "ApplicationCookie",
LoginPath = new PathString("/default.aspx"),
ExpireTimeSpan = 15
});