Patch for nginx handling of X-Accel-Redirect URLs

vitalif at vitalif at
Tue Jan 31 23:51:18 UTC 2012


By now, nginx does not allow urlencoded X-Accel-Redirect URLs and 
totally fails to access files with '?' in name with it.
The problem was also discussed at 'nginx' maillist:

The patch suggested there just unescaped the url in 
ngx_http_parse_unsafe_uri(). As Maxim Dounin said, this is incorrect 
because also unescapes the query string.
I want to suggest another solution - swap ngx_http_parse_unsafe_uri() 
to ngx_http_parse_complex_uri(). The patch is in attachment.
What can you say about it?
-------------- next part --------------
An embedded and charset-unspecified text was scrubbed...
Name: patch-nginx-x-accel-uri-parsing.diff
URL: <>

More information about the nginx-devel mailing list