services.AddAuthentication(CookieAuthenticationDefaults.AuthenticationScheme)
.AddCookie(options =>
{
options.Cookie.Name = "TestCookie1";
options.LoginPath = new PathString("/Account/Login");
options.AccessDeniedPath = new PathString("/Account/Denied");
})
.AddCookie(options =>
{
options.Cookie.Name = "TestCookie2";
options.LoginPath = new PathString("/Account/Login");
options.AccessDeniedPath = new PathString("/Account/Denied");
});.Net Core Cookie 認證,怎么寫入兩個 Cookie?上面這樣寫是不能運行的
- 1 回答
- 0 關注
- 739 瀏覽
添加回答
舉報
0/150
提交
取消