用户名:
密 码: 记住
您当前的位置:首页 > 站长百科 > 服务器技术

IIS URL Rewrite Module防盗链规则配置方法

时间:2015-01-18  来源:互联网  作者:佚名

IIS版本:IIS 7.5

URL Rewrite组件:IIS URL Rewrite Module(http://www.iis.net/downloads/microsoft/url-rewrite)

规则定义截图:

Web.config中的规则定义:

. 代码如下:
<rewrite>
    <rules>
        <rule name="RequestBlockingRule1" enabled="true" stopProcessing="true">
            <match url=".*" />
            <conditions>
                <add input="{HTTP_REFERER}" pattern="^$" negate="true" />
                <add input="{HTTP_REFERER}" pattern="^http://(.*\.)?(cnblogs\.com)/.*$" negate="true" />
            </conditions>
            <action type="CustomResponse" statusCode="404" />
        </rule>
    </rules>
</rewrite>

来顶一下
返回首页
返回首页
推荐资讯
【图文教程】dede织梦网站后台如何发表文章? 【图文教程】dede织梦网站后台如何对于新手站长可能不了解,dede织梦后台是如何发文章的。下面
2014站长圈十大事件:PR已死 移动算法兴起 2014站长圈十大事件:PR已死 移动算2014年即将过去,虽然站长圈相比过去几年稍显沉寂,但&ldquo
相关文章
    无相关信息
栏目更新
栏目热门