using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using Microsoft.AspNetCore.Authentication;
namespace AuthStudy.Authentication.Browser
{
public class BrowserAuthenticationOptions : AuthenticationSchemeOptions
{
///
/// 允许的浏览器
///
public List AllowBrowsers { get; set; } = new List();
///
/// 允许移动设备
///
public bool AllowMobile { get; set; } = true;
///
/// 允许爬虫
///
public bool AllowSpider { get; set; }
public BrowserAuthenticationOptions() :
this(null, true, true)
{
}
public BrowserAuthenticationOptions(List? allowedBrowsers, bool allowedMMobile, bool allowedSpider)
{
AllowBrowsers = allowedBrowsers ?? BrowserAuthenticationDefault.AllowBrowsers;
AllowMobile = allowedMMobile;
AllowSpider = allowedSpider;
}
}
}