aboutsummaryrefslogtreecommitdiff
path: root/src/http/modules/ngx_http_referer_module.c
diff options
context:
space:
mode:
authorIgor Sysoev <igor@sysoev.ru>2006-01-24 16:08:27 +0000
committerIgor Sysoev <igor@sysoev.ru>2006-01-24 16:08:27 +0000
commit34303468409089ef2b5bd9739b9c049c393932e4 (patch)
tree1e47f167cd74beaeca64d863662ed1e82d2cf822 /src/http/modules/ngx_http_referer_module.c
parentd94e18746b9e79fbb52cf3012d1692ad893df22e (diff)
downloadnginx-release-0.3.23.tar.gz
nginx-release-0.3.23.zip
nginx-0.3.23-RELEASE importrelease-0.3.23
*) Feature: the "optimize_host_names" directive. *) Bugfix: in using of the variables in the "path" and "alias" directives. *) Bugfix: the ngx_http_perl_module was incorrectly built on Linux and Solaris.
Diffstat (limited to 'src/http/modules/ngx_http_referer_module.c')
-rw-r--r--src/http/modules/ngx_http_referer_module.c10
1 files changed, 10 insertions, 0 deletions
diff --git a/src/http/modules/ngx_http_referer_module.c b/src/http/modules/ngx_http_referer_module.c
index 459984eaa..17a3427ca 100644
--- a/src/http/modules/ngx_http_referer_module.c
+++ b/src/http/modules/ngx_http_referer_module.c
@@ -216,6 +216,16 @@ ngx_http_referer_merge_conf(ngx_conf_t *cf, void *parent, void *child)
return NGX_CONF_OK;
}
+ if ((conf->no_referer == 1 || conf->blocked_referer == 1)
+ && conf->keys->keys.nelts == 0 && conf->keys->dns_wildcards.nelts)
+ {
+ ngx_log_error(NGX_LOG_EMERG, cf->log, 0,
+ "the \"none\" or \"blocked\" referers are specified "
+ "in the \"valid_referers\" directive "
+ "without any valid referer");
+ return NGX_CONF_ERROR;
+ }
+
hash.key = ngx_hash_key_lc;
hash.max_size = 2048; /* TODO: referer_hash_max_size; */
hash.bucket_size = 64; /* TODO: referer_hash_bucket_size; */