lnmpa 1.1防盗链失败,设置貌似没问题!求指点
server{
listen 80;
#listen [::]:80;
server_name wuraowo.com;
index index.html index.htm index.php default.html default.htm default.php;
root/home/wwwnet/wuraowo;
location / {
try_files $uri @apache;
}
location @apache {
internal;
proxy_pass http://127.0.0.1:88;
include proxy.conf;
}
location ~ [^/]\.php(/|$)
{
proxy_pass http://127.0.0.1:88;
include proxy.conf;
}
location ~ .*\.(js|css)?$
{
expires 12h;
}
location ~ .*\.(gif|jpg|jpeg|png|bmp|swf)$
{
valid_referers none blocked *.wuraowo.com;
if ($invalid_referer)
{
rewrite ^/ http://ckvip.com/error.jpg;
#return 403;
}
}
access_log off;
}/usr/local/nginx/sbin/nginx -t
nginx: the configuration file /usr/local/nginx/conf/nginx.conf syntax is ok
nginx: configuration file /usr/local/nginx/conf/nginx.conf test is successful貌似没有用
HttpAccessKeyModule模版需要重新编译才有吗,默认有这个模块吗
[ 本帖最后由 coo 于 2015-1-29 23:51 编辑 ] 加到root行下面,重启nginx
你说的HttpAccessKeyModule和用valid_referers是不一样的模块
HttpAccessKeyModule是不默认安装的 http://www.thexq.com/wp-content/uploads/2015/08/640.jpg测试下我的设置:lol 原帖由 9o8i7u 于 2015-8-11 01:59 发表 http://bbs.vpser.net/images/common/back.gif
http://www.thexq.com/wp-content/uploads/2015/08/640.jpg测试下我的设置:lol 没防盗,可以打开 https://inwao.com/usr/uploads/2019/11/3622936304.png测试一下
页:
[1]