VersionNegotiationFilter pops off the version string of PATH_INFO,
the popped segment is pushed onto SCRIPT_NAME, which results in
dual version strings (e.g. '/v1/v1/') in the 'Location' header
of a redirect response. This may result in a further 404 error
if the http client will automatically follow the returned
redirect.
Fix this problem by adding a private method which does not
push the popped segment onto SCRIPT_NAME.
Reviewed: https:/ /review. openstack. org/28217 github. com/openstack/ glance/ commit/ abbc53533360015 72290feb8d06d65 094b83a7cf
Committed: http://
Submitter: Jenkins
Branch: master
commit abbc53533360015 72290feb8d06d65 094b83a7cf
Author: James Li <email address hidden>
Date: Fri May 3 22:31:58 2013 +0000
Redirects requests from /v# to /v#/ with correct Location header
This is a continuous fix to bug #1166957
VersionNego tiationFilter pops off the version string of PATH_INFO,
the popped segment is pushed onto SCRIPT_NAME, which results in
dual version strings (e.g. '/v1/v1/') in the 'Location' header
of a redirect response. This may result in a further 404 error
if the http client will automatically follow the returned
redirect.
Fix this problem by adding a private method which does not
push the popped segment onto SCRIPT_NAME.
Change-Id: Ie0c244af38534d de2058828fbff84 0a845cc7c90
Fixes: bug #1175815