最近发现公司图片服务器上有盗链现象,图片服务器是用lighttpd提供web服务的,因此在lighttpd上加防盗链。配置如下
$HTTP["referer"] !~ "^($|http://.*.xxx.com.(cn|hk))"{
url.access-deny = (".jpg",".jpeg",".png",".gif",".ico",".bmp")
}
$HTTP["referer"] !~ "^($|http://.*.xxx.com.(cn|hk))"{
url.access-deny = (".jpg",".jpeg",".png",".gif",".ico",".bmp")
}
来自 “ ITPUB博客 ” ,链接:http://blog.itpub.net/27181165/viewspace-1063586/,如需转载,请注明出处,否则将追究法律责任。
转载于:http://blog.itpub.net/27181165/viewspace-1063586/