string servername = Request.ServerVariables["SERVER_NAME"];
string referer = Request.ServerVariables["HTTP_REFERER"];
Uri uri = new Uri(referer);
if (servername != uri.Host)
{
throw new WarnException("您提交的路径有误,禁止从站点外部提交数据!");
}
string servername = Request.ServerVariables["SERVER_NAME"];
string referer = Request.ServerVariables["HTTP_REFERER"];
Uri uri = new Uri(referer);
if (servername != uri.Host)
{
throw new WarnException("您提交的路径有误,禁止从站点外部提交数据!");
}
上一篇:json数据反序列化成数据实体
redis缓存 setIfAbsent防止重复提交
举报文章
请选择举报类型
补充说明
0/200
上传截图
格式支持JPEG/PNG/JPG,图片不超过1.9M