httpd-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Guillaume Fraysse <>
Subject [users@httpd] mod_proxy : ProxyPassReverse and regex ?
Date Tue, 25 Aug 2009 15:05:30 GMT
Hello to the list,

I'm trying to put up some vodoo Reverse Proxy Configuration on 2.2.11
(64bits, linux) apache build.
What I'm trying to achieve is that all URL such as are redirected to intranet URLs such as

I'm using regex, mod_rewrite and mod_proxy for that and it's working just
fine but I'm facing a problem when one of the web application behind my
reverse proxy use a "Location:" header. In this case the user gets an
intranet URL  which he can't access. ProxyPassReverse semmes to be the
adequate answer but doens't seem to support regex

Sample :
I currently have :
RewriteCond %{REQUEST_URI} ^/(.*)/bob.*
RewriteRule ^/(.*)/bob(.*) http://$1.intranet/$1/bob$2 [P,L] and this works

it seems natural to have a rule such as :
ProxyPassReverse /(.*)/bob/ http://$1.intranet/$1/bob

but this doesn't seem to be possible with ProxyPassReverse.

So I have a few questions :
- are regex supported in ProxyPassReverse ?
- is there a workaround ? I'd like to avoid hard-coded ProxyPassReverse
rules in my apache configuration.

Best regards,

View raw message