RE: apache2 mod_rewrite + mod_proxy internal proxying problem

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



You cannot use that combination of RewriteRule and ProxyPass. The fact is that ProxyPass actually gets the upper hand on RewriteRule. Furthermore you MUST specify the destination host in your RewriteRule when using the P flag. I would also drop the IfModule tests for any module which is necessary for the correct operation of your server.  It is better to get an error during initialisation clearly indicating that it will not work as intended.

Try the following configuration:

RewriteEngine On
RewriteLog rewrite.log
RewriteLogLevel 9
RewriteRule ^/meat(.*) http://arifolth/handbook.html [P,L]

ProxyRequests Off

ProxyPassReverse /handbook.html http://arifolth


-ascs

-----Message d'origine-----
De : Arifolth [mailto:arifolth@xxxxxxx] 
Envoyé : mardi 13 novembre 2007 15:37
À : users@xxxxxxxxxxxxxxxx
Objet :  apache2 mod_rewrite + mod_proxy internal proxying problem

Hi All!

I need to substitute requested page with aniother, i. e. if client has reqested page http://arifolth/meat[anything].html
he should get http://arifolth/handbook.html as far as I understand reverse proxyfying is the only right way to do it mod rewrite alone works fine, it gave error 302 to the client  - the document has moved ...
but I need to get not a redirection reply but the substituted page itself. when I`m trying to use mod_proxy things are gone bad: server`s answer is always 403 - Access forbidden!

---------------------------------------------------------------------
The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:http://httpd.apache.org/userslist.html> for more info.
To unsubscribe, e-mail: users-unsubscribe@xxxxxxxxxxxxxxxx
   "   from the digest: users-digest-unsubscribe@xxxxxxxxxxxxxxxx
For additional commands, e-mail: users-help@xxxxxxxxxxxxxxxx



[Index of Archives]     [Open SSH Users]     [Linux ACPI]     [Linux Kernel]     [Linux Laptop]     [Kernel Newbies]     [Security]     [Netfilter]     [Bugtraq]     [Squid]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Samba]     [Video 4 Linux]     [Device Mapper]

  Powered by Linux