Welcome! Log In Create A New Profile

Advanced

[nginx] Referer module: added $invalid_referer to variables hash.

Maxim Dounin
May 22, 2013 02:56PM
details: http://hg.nginx.org/nginx/rev/8f74cf107137
branches:
changeset: 5221:8f74cf107137
user: Maxim Dounin <mdounin@mdounin.ru>
date: Wed May 22 22:31:53 2013 +0400
description:
Referer module: added $invalid_referer to variables hash.

This makes it accessible via dynamic lookup with ngx_http_get_variable()
from Perl, SSI, etc.

Patch by Yichun Zhang (agentzh).

diffstat:

src/http/modules/ngx_http_referer_module.c | 3 +--
1 files changed, 1 insertions(+), 2 deletions(-)

diffs (13 lines):

diff --git a/src/http/modules/ngx_http_referer_module.c b/src/http/modules/ngx_http_referer_module.c
--- a/src/http/modules/ngx_http_referer_module.c
+++ b/src/http/modules/ngx_http_referer_module.c
@@ -396,8 +396,7 @@ ngx_http_valid_referers(ngx_conf_t *cf,

ngx_str_set(&name, "invalid_referer");

- var = ngx_http_add_variable(cf, &name,
- NGX_HTTP_VAR_CHANGEABLE|NGX_HTTP_VAR_NOHASH);
+ var = ngx_http_add_variable(cf, &name, NGX_HTTP_VAR_CHANGEABLE);
if (var == NULL) {
return NGX_CONF_ERROR;
}

_______________________________________________
nginx-devel mailing list
nginx-devel@nginx.org
http://mailman.nginx.org/mailman/listinfo/nginx-devel
Subject Author Views Posted

[nginx] Referer module: added $invalid_referer to variables hash.

Maxim Dounin 1120 May 22, 2013 02:56PM



Sorry, you do not have permission to post/reply in this forum.

Online Users

Guests: 205
Record Number of Users: 8 on April 13, 2023
Record Number of Guests: 421 on December 02, 2018
Powered by nginx      Powered by FreeBSD      PHP Powered      Powered by MariaDB      ipv6 ready