<rewrite>
<rules>
<clear />
<!--
屏蔽低版本IE浏览器
返回信息:
终止访问
-->
<rule name="Blank bot" enabled="true" stopProcessing="true">
<match url="(.*)" ignoreCase="true" negate="false" />
<conditions logicalGrouping="MatchAny" trackAllCaptures="false">
<add input="{HTTP_USER_AGENT}" pattern="Mozilla/4\.0 \(compatible; MSIE \d.0; Windows NT \d.1(; SV1)?\)" />
</conditions>
<action type="AbortRequest" />
</rule>
<!--
屏蔽多蜘蛛标识拼接
返回信息:
终止访问
-->
<rule name="Blank_Bot_M" stopProcessing="true">
<match url=".*" />
<conditions logicalGrouping="MatchAll" trackAllCaptures="false">
<add input="{HTTP_USER_AGENT}" pattern="Baiduspider" />
<add input="{HTTP_USER_AGENT}" pattern="Googlebot" />
</conditions>
<action type="AbortRequest" />
</rule>
<!--
判断带百度蜘蛛标示的请求(完整UserAgent)是否与官网匹配
返回信息:
终止访问
-->
<rule name="BaiduSpider" stopProcessing="true">
<match url=".*" />
<conditions logicalGrouping="MatchAll" trackAllCaptures="false">
<add input="{HTTP_USER_AGENT}" pattern="Baiduspider" />
<add input="{HTTP_USER_AGENT}" pattern="Mozilla/5\.0 \(compatible; Baiduspider(-render)?/2\.0; \+http://www\.baidu\.com/search/spider\.html\)" negate="true" />
</conditions>
<action type="AbortRequest" />
</rule>
<!--
match: 判断访问user.php文件的请求
conditions_1: 来访者UserAgent不为空
conditions_2: 来访者UserAgent 必须满足正确的Url格式
返回信息:
statusDescription: 一串二进制字符,翻译成中文是: 你是傻逼
-->
<rule name="No Referer" stopProcessing="true">
<match url="user.php" />
<conditions>
<add input="{HTTP_REFERER}" pattern="^$" negate="true" />
<add input="{HTTP_REFERER}" pattern="^http(s)?://[0-9a-z-\.]+(/.*)?$" negate="true" />
</conditions>
<action type="CustomResponse" statusCode="404" subStatusCode="666" statusReason="may not" statusDescription="111001001011110110100000 111001101001100010101111 111001111000010110011110 111001111010110010010100" />
</rule>
</rules>
</rewrite>
百度:https://ziyuan.baidu.com/ (需登录提交)360:http://info.so.360.cn/site_submit.html (可直接提交)搜狗:http://zhanzhang.sogou.com/index.php/sitelink/index (需登录提交)谷歌:http://www.google.cn/intl/zh-CN/add_url.html (google中国已关闭)移动搜索:头条:https://zhanzhang.toutiao.com/page/inner/site/add (需登录提交)神马:https://zhanzhang.sm..