【发布时间】:2014-03-25 00:35:15
【问题描述】:
我正在使用 mvc 5 与 facebook 进行外部登录,但每次服务器重新启动后,用户都会从系统中注销。这违背了 oAuth 的目的?我找不到任何属性让它们在重新启动后仍然存在
这就是 startup.auth 的样子..
app.UseCookieAuthentication(new CookieAuthenticationOptions
{
AuthenticationType = DefaultAuthenticationTypes.ApplicationCookie,
LoginPath = new PathString("/Account/External"),
ExpireTimeSpan = new TimeSpan(30, 0, 0, 0),
SlidingExpiration = true
});
app.UseExternalSignInCookie(DefaultAuthenticationTypes.ExternalCookie);
【问题讨论】:
标签: c# .net asp.net-mvc-5 asp.net-identity owin