Issue with proxy_cache_key after rewrite

Eugaia ngx.eugaia at
Sat Dec 25 04:41:18 MSK 2010


On 25/12/2010 03:29, Piotr Sikora wrote:
>> So i've added the following:
>> proxy_cache_key "$scheme$host$request_uri";
> Try using "$scheme$host$uri$is_args$args" ;)
Probably putting '://' or something else that won't be the first 
character of a URL (e.g. '#') between $scheme and $host is a good idea, 
just in case you have two hosts that only differ by an initial 's' -

e.g. and

https + = http +

In most situations this will be fine, but depending on the setup, it 
could potentially be a source of bugs or a security hole.


More information about the nginx mailing list