Welcome! Log In Create A New Profile

Advanced

Bug? Inconsistent url encoding in X-Accel-Redirect

Brian Moran
April 21, 2009 12:52PM
I believe I've found an inconsistency in url encoding of
X-Accel-Redirect requests.

The URL that I'm providing in my X-Accel-Redirect header looks something
like:
/BACKING_HOST_LOCATION/Green%20Apple.gif?param1=TzJPvoCEV34&param2=U%2F8%3D

When this is supplied to nginx, the PATH part of the url gets url
encoded, however the parameters are passed untouched to the upstream
(sniffed with wireshark):

GET /Green%2520Apple.gif?param1=TzJPvoCEV34&param2=U%2F8%3D

(everything BEFORE the ? is urlencoded, the params are not)

I have a really, really gross hack where I only url encode the
parameters to be supplied, and leave the path alone, then pass to nginx
but this seems like a bug to me.

It would be convenient to have greater control of the the
X-Accel-Redirect urlencoding process; there are some times when I'd like
to supply a pre-encoded URL and pass it unchanged to the upstream.

I have tried this in 0.7.6, believe it also occurs in 0.6.x

bmoran -a-t- onehub.com
Subject Author Posted

Bug? Inconsistent url encoding in X-Accel-Redirect

Brian Moran April 21, 2009 12:52PM

Repost: Inconsistent URL encoding in X-Accel-Redirect

Brian Moran May 05, 2009 07:44PM

Re: Repost: Inconsistent URL encoding in X-Accel-Redirect

Igor Sysoev May 06, 2009 12:40AM

Re: Repost: Inconsistent URL encoding in X-Accel-Redirect

Brian Moran May 11, 2009 05:56PM



Sorry, only registered users may post in this forum.

Click here to login

Online Users

Guests: 298
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