Apache 防盗链

一月 8th, 2010 Posted in Apache | 阅读次数: 417 次

原文:http://www.hiadmin.com/?p=928

临时要求在apache中加防盗链。网上搜集了一些资料整理一下发在这里,方便以后翻阅。
关于mod_authz_host模块参看:http://doc.linuxpk.com/doc/apache/mod/mod_authz_host.html
1。通过User-Agent浏览器类型限制

SetEnvIf User-Agent ^blueapple go_out
<directory /home/domain>
Order Allow,Deny
Allow  from all
Deny from env=go_out
</directory>

2。通过Referer限制

SetEnvIf Referfer ^$ go_out
SetEnvIf Referfer ^http:\/\/baidu.com(\/|$)”  go_out
<directory /home/domain>
Order Allow,Deny
Allow  from all
Deny from env=go_out
</directory>

referer为空禁止访问。
referer为http://baidu.com限制访问。

相关日志:

Tags:

5 Responses to “Apache 防盗链”

  1. How to Lose Love Handles Fast Says:

    Lose Love Handles Fast…

    [...]below you’ll see my links page http://www.loselovehandlesfastblog.com/links/ with some fantastic sites that I think you should definitely go visit[...]…


  2. Resources Says:

    My Recommended Websites…

    [...]some new websites on the web we love, even if they are not related to ours. Check them out[...]…


  3. juicy couture tracksuit Says:

    sdsd


  4. yeast infection cure Says:

    Related Websites…

    [...]here are some other links to sites that we find everyday so here are some popular sites we like today[...]…


  5. google plus guide Says:

    [...]the time to read or visit the content or sites we have linked to below the[...]……

    [...]here are some links to sites that we link to because we think they are worth visiting[...]……


留下您的脚印