ISAPI_Rewrite圖片防盜鏈不起作用經(jīng)驗總結(jié)
廣告:
ISAPI_Rewrite圖片防盜鏈不起作用經(jīng)驗總結(jié):
1. ISAPI_Rewrite非full版
2. ISAPI_Rewrite已過期
3. iis沒有配好(擴展允許、網(wǎng)站上篩選器要加上dll)
4. httpd.ini里面沒有寫好正則
httpd.ini示例
[ISAPI_Rewrite]
# 3600 = 1 hour
CacheClockRate 3600
RepeatLimit 32
# Block external access to the httpd.ini and
httpd.parse.errors files
RewriteRule /httpd(?:\.ini|\.parse\.errors).* / [F,I,O]
# Block external access to the Helper ISAPI Extension
RewriteRule .*\.isrwhlp / [F,I,O]
RewriteCond Host: (.+)
RewriteCond Referer: (?!http://\1.*).*
RewriteCond Referer: (?!http://
(.*\.1718vip\.com|.*\.scef\.com\.cn|.*\.smtpcb\.com\.cn|.*
\.laserfair\.cn|.*\.laserfair\.com\.cn|.*\.hkgii\.com|.*\.
cha600\.com)).*
# RewriteCond Referer: ^(?!http://
(.*\.1718vip\.com|.*\.scef\.com\.cn|.*\.smtpcb\.com\.cn|.*
\.laserfair\.cn|.*\.laserfair\.com\.cn|.*\.hkgii\.com|.*\.
cha600\.com)).*$
# RewriteCond Referer: ^(?!http://
(.*\.1718vip\.com|.*\.scef\.com\.cn|.*\.smtpcb\.com\.cn|.*
\.laserfair\.cn|.*\.laserfair\.com\.cn|.*\.hkgii\.com|.*\.
cha600\.com).*).*$
RewriteRule .*\.(?:gif|jpg|png|exe|rar|zip|mp3|swf)
/Block.gif [I,O,N]
廣告: