apache urlrewrite防盗链功能配置
时间:2021-08-15 09:34:58|栏目:Linux|点击: 次
DocumentRoot /home/img
ServerName img.host.com
ErrorDocument 404 /
RewriteEngine on
RewriteCond %{HTTP_REFERER} !^$
RewriteCond %{HTTP_REFERER} !^http://img.host.com/.*$ [NC]
RewriteCond %{HTTP_REFERER} !^http://www.host.com/.*$ [NC]
RewriteRule \.(gif|jpg|jpeg)$ http://img.host.com/forbidden.png [R,L]
ServerName img.host.com
ErrorDocument 404 /
RewriteEngine on
RewriteCond %{HTTP_REFERER} !^$
RewriteCond %{HTTP_REFERER} !^http://img.host.com/.*$ [NC]
RewriteCond %{HTTP_REFERER} !^http://www.host.com/.*$ [NC]
RewriteRule \.(gif|jpg|jpeg)$ http://img.host.com/forbidden.png [R,L]
上一篇:Apache、Nginx下Font Awesome在 Firefox 中不显示问题解决方法
栏 目:Linux
下一篇:linux命令之目录监控 字符串拆分 监控命令运行结果 统计行数 去除文本头尾空格 获取网卡名浮点数运算等命令使用技巧
本文地址:http://www.codeinn.net/misctech/167149.html






