When using ngx_var_get to get nginx variables the function will core dump on some variables if they are not set.
EX: ngx_var_get("referer"); will result in a core if the header doesn't exist. it works if the header is set. The work around is to put this in the nginx config:
set $ref $http_referer;
and use: ngx_var_get("ref");
However, if one uses:
ngx_var_get("https");
it will not core nginx if the variable https is not set in nginx
When using ngx_var_get to get nginx variables the function will core dump on some variables if they are not set.
EX: ngx_var_get("referer"); will result in a core if the header doesn't exist. it works if the header is set. The work around is to put this in the nginx config: set $ref $http_referer; and use: ngx_var_get("ref");
However, if one uses: ngx_var_get("https"); it will not core nginx if the variable https is not set in nginx