|
|
@ -0,0 +1,35 @@
|
|
|
|
|
|
|
|
using System;
|
|
|
|
|
|
|
|
using System.Collections.Generic;
|
|
|
|
|
|
|
|
using System.Linq;
|
|
|
|
|
|
|
|
using System.Threading.Tasks;
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
namespace CorsServer.WebApi31
|
|
|
|
|
|
|
|
{
|
|
|
|
|
|
|
|
public class CorsOption
|
|
|
|
|
|
|
|
{
|
|
|
|
|
|
|
|
/// <summary>
|
|
|
|
|
|
|
|
/// 策略名称
|
|
|
|
|
|
|
|
/// </summary>
|
|
|
|
|
|
|
|
public string PolicyName { get; set; }
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
/// <summary>
|
|
|
|
|
|
|
|
/// 允许跨域的域名列表
|
|
|
|
|
|
|
|
/// </summary>
|
|
|
|
|
|
|
|
public List<string> Origins { get; set; }
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
/// <summary>
|
|
|
|
|
|
|
|
/// 允许跨域的方法
|
|
|
|
|
|
|
|
/// </summary>
|
|
|
|
|
|
|
|
public List<string> Methods { get; set; }
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
/// <summary>
|
|
|
|
|
|
|
|
/// 允许跨域的请求头
|
|
|
|
|
|
|
|
/// </summary>
|
|
|
|
|
|
|
|
public List<string> Headers { get; set; }
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
/// <summary>
|
|
|
|
|
|
|
|
/// 允许跨域的ExposedHeader
|
|
|
|
|
|
|
|
/// </summary>
|
|
|
|
|
|
|
|
public List<string> ExposedHeaders { get; set; }
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
}
|