Mailing List Archive

[Bug 57691] mod_proxy/proxy_util confuses UDS scheme with HTTP scheme when using RewriteRule
https://bz.apache.org/bugzilla/show_bug.cgi?id=57691

Chris Seufert <chris@modd.com.au> changed:

What |Removed |Added
----------------------------------------------------------------------------
Resolution|FIXED |---
Status|RESOLVED |REOPENED

--- Comment #11 from Chris Seufert <chris@modd.com.au> ---
I am not sure this is fixed for all cases.

I have recently run into an issue with the following config:

<If "true" >
RewriteEngine On
RewriteCond "%{REQUEST_URI}" !^/___proxy_me/
RewriteRule ^/(.*)$ "/___proxy_me/$1"
# [L,NE,B=%\ |:]
</If>
ProxyPass /___proxy_me/ "http://backend/" upgrade=websocket

What ends up happening is the backend server receives a url like:
%{document_root}%{request_uri}

From logs of two apache servers main proxying to backend running in docker:

backend-1 | 172.21.0.2 - - [24/Mar/2024:10:49:02 +0000] "GET
/usr/local/apache2/htdocs/ HTTP/1.1" 404 196
main-1 | 172.21.0.1 - - [24/Mar/2024:10:49:02 +0000] "GET / HTTP/1.1" 404
196
backend-1 | 172.21.0.3 - - [24/Mar/2024:11:06:25 +0000] "GET
/usr/local/apache2/htdocs/test-url.html HTTP/1.1" 404 196
main-1 | 172.21.0.1 - - [24/Mar/2024:11:06:25 +0000] "GET /test-url.html
HTTP/1.1" 404 196

for repoduction using latest docker image version:
https://github.com/cseufert/apache-proxy-test-2

--
You are receiving this mail because:
You are the assignee for the bug.
---------------------------------------------------------------------
To unsubscribe, e-mail: bugs-unsubscribe@httpd.apache.org
For additional commands, e-mail: bugs-help@httpd.apache.org
[Bug 57691] mod_proxy/proxy_util confuses UDS scheme with HTTP scheme when using RewriteRule [ In reply to ]
https://bz.apache.org/bugzilla/show_bug.cgi?id=57691

Yann Ylavic <ylavic.dev@gmail.com> changed:

What |Removed |Added
----------------------------------------------------------------------------
Status|REOPENED |RESOLVED
Resolution|--- |FIXED

--- Comment #12 from Yann Ylavic <ylavic.dev@gmail.com> ---
(In reply to Chris Seufert from comment #11)
> I am not sure this is fixed for all cases.

This might work with a RewriteRule [PT] flag.

I don't see how this (convoluted) configuration relates to this ticket though
(no "unix:" scheme involved), set to RESOLVED again.

--
You are receiving this mail because:
You are the assignee for the bug.
---------------------------------------------------------------------
To unsubscribe, e-mail: bugs-unsubscribe@httpd.apache.org
For additional commands, e-mail: bugs-help@httpd.apache.org