mirror of
https://gitee.com/dotnetchina/OpenAuth.Net.git
synced 2026-01-22 21:01:49 +08:00
去掉Owin的一些代码
This commit is contained in:
@@ -1,38 +0,0 @@
|
||||
using Microsoft.AspNet.Identity;
|
||||
using Microsoft.Owin;
|
||||
using Microsoft.Owin.Security.Cookies;
|
||||
using Owin;
|
||||
|
||||
namespace OpenAuth.Mvc
|
||||
{
|
||||
public partial class Startup
|
||||
{
|
||||
// 有关配置身份验证的详细信息,请访问 http://go.microsoft.com/fwlink/?LinkId=301864
|
||||
public void ConfigureAuth(IAppBuilder app)
|
||||
{
|
||||
// 使应用程序可以使用 Cookie 来存储已登录用户的信息
|
||||
app.UseCookieAuthentication(new CookieAuthenticationOptions
|
||||
{
|
||||
AuthenticationType = DefaultAuthenticationTypes.ApplicationCookie,
|
||||
LoginPath = new PathString("/Account/Login")
|
||||
});
|
||||
// Use a cookie to temporarily store information about a user logging in with a third party login provider
|
||||
app.UseExternalSignInCookie(DefaultAuthenticationTypes.ExternalCookie);
|
||||
|
||||
// 取消注释以下行可允许使用第三方登录提供程序登录
|
||||
//app.UseMicrosoftAccountAuthentication(
|
||||
// clientId: "",
|
||||
// clientSecret: "");
|
||||
|
||||
//app.UseTwitterAuthentication(
|
||||
// consumerKey: "",
|
||||
// consumerSecret: "");
|
||||
|
||||
//app.UseFacebookAuthentication(
|
||||
// appId: "",
|
||||
// appSecret: "");
|
||||
|
||||
//app.UseGoogleAuthentication();
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user