Mercurial > hg > nginx-quic
comparison src/http/modules/ngx_http_rewrite_module.c @ 4972:8b635cf36ccc
Added checks that disallow adding a variable with an empty name.
Added variable name syntax checks to "geo" and "map" directives.
author | Ruslan Ermilov <ru@nginx.com> |
---|---|
date | Mon, 17 Dec 2012 19:03:33 +0000 |
parents | 9f4cdc7a8578 |
children | 16a371063d20 |
comparison
equal
deleted
inserted
replaced
4971:eaf95350d75c | 4972:8b635cf36ccc |
---|---|
906 ngx_http_script_var_code_t *vcode; | 906 ngx_http_script_var_code_t *vcode; |
907 ngx_http_script_var_handler_code_t *vhcode; | 907 ngx_http_script_var_handler_code_t *vhcode; |
908 | 908 |
909 value = cf->args->elts; | 909 value = cf->args->elts; |
910 | 910 |
911 if (value[1].len < 2 || value[1].data[0] != '$') { | 911 if (value[1].data[0] != '$') { |
912 ngx_conf_log_error(NGX_LOG_EMERG, cf, 0, | 912 ngx_conf_log_error(NGX_LOG_EMERG, cf, 0, |
913 "invalid variable name \"%V\"", &value[1]); | 913 "invalid variable name \"%V\"", &value[1]); |
914 return NGX_CONF_ERROR; | 914 return NGX_CONF_ERROR; |
915 } | 915 } |
916 | 916 |