Is there a way to use "proxy_pass" without having it unescape the characters in the uri?<br><br>For example, using the following configuration:<br><br> location /my_proxy/ {<br>
proxy_set_header Host $http_host;<br>
proxy_set_header X-Real-IP $remote_addr;<br>
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;<br>
proxy_redirect off;<br><br>
proxy_pass <a href="http://my_proxy/">http://my_proxy/</a>;<br>
}<br><br>A request to "/my_proxy/sites/http%3A%2F%2Fwww%2eexample%2ecom" will arrive to the my_proxy server as "/sites/<a href="http://www.example.com">http://www.example.com</a>", instead of "sites/http%3A%2F%2Fwww%2eexample%2ecom".<br>
<br>You can get the raw format by removing the slash at the end of the proxy_pass:<br><br>
location /my_proxy/ {<br>
proxy_set_header Host $http_host;<br>
proxy_set_header X-Real-IP $remote_addr;<br>
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;<br>
proxy_redirect off;<br>
<br>
proxy_pass <a href="http://my_proxy">http://my_proxy</a>;<br>
}<br><br>Now, a request to "/my_proxy/sites/http%3A%2F%2Fwww%2eexample%2ecom" will
arrive to the my_proxy server as "my_proxy/sites/http%3A%2F%2Fwww%2eexample%2ecom",
instead of "sites/http%3A%2F%2Fwww%2eexample%2ecom".<br>I would like "my_proxy" would to gone but the rest of the uri to remain escaped.<br><br>I've tried manually rewriting like so:<br><br> location /my_proxy/ {<br>
proxy_set_header Host $http_host;<br> proxy_set_header X-Real-IP $remote_addr;<br> proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;<br> proxy_redirect off;<br><br> rewrite /my_proxy/(.*) /$1 break;<br>
proxy_pass <a href="http://my_proxy">http://my_proxy</a>;<br> }<br><br>However, this results in the same behavior as the first example (where the unescaping still occurs.)<br clear="all"><br>-- <br>Respectfully,<br>
Larry Diehl<br><a href="http://www.larrytheliquid.com">www.larrytheliquid.com</a>