From ccsmrh@bath.ac.uk Tue Jun 10 10:16:51 1997 Received: from goggins.bath.ac.uk (pp@goggins.bath.ac.uk [138.38.32.13]) by hyperreal.com (8.8.5/8.8.5) with ESMTP id KAA16777 for ; Tue, 10 Jun 1997 10:16:50 -0700 (PDT) Message-Id: <9706101816.aa14361@amos.bath.ac.uk> Date: Tue, 10 Jun 1997 18:16:13 +0100 From: Mark Hindess To: apbugs@hyperreal.com Cc: rse@engelschall.com Subject: Strange interaction between mod_rewrite and proxy module >Number: 713 >Category: mod_proxy >Synopsis: Strange interaction between mod_rewrite and proxy module >Confidential: yes >Severity: serious >Priority: medium >Responsible: apache >State: closed >Class: sw-bug >Submitter-Id: unknown >Arrival-Date: Tue Jun 10 10:20:01 1997 >Last-Modified: Mon Aug 18 02:41:01 PDT 1997 >Originator: ccsmrh@bath.ac.uk >Organization: >Release: 1.2.0 >Environment: >Description: >How-To-Repeat: >Fix: >Audit-Trail: Originator-Changed-From-To: -ccsmrh@bath.ac.uk Originator-Changed-By: coar Originator-Changed-When: Thu Jun 12 03:13:54 PDT 1997 Release-Changed-From-To: -1.2.0 Release-Changed-By: coar Release-Changed-When: Thu Jun 12 03:13:54 PDT 1997 Responsible-Changed-From-To: gnats-admin (GNATS administrator)-apache Responsible-Changed-By: coar Responsible-Changed-When: Thu Jun 12 03:13:54 PDT 1997 Responsible-Changed-Why: Moving into the mainstream bugdb Category-Changed-From-To: pending-mod_proxy Category-Changed-By: coar Category-Changed-When: Thu Jun 12 03:13:54 PDT 1997 State-Changed-From-To: open-closed State-Changed-By: Lars.Eilebrecht@unix-ag.org State-Changed-When: Wed Aug 6 05:58:59 PDT 1997 State-Changed-Why: The ProxyRemote directive is broken. We are already tracking this in PR #656. Comment-Added-By: Lars.Eilebrecht@unix-ag.org Comment-Added-When: Mon Aug 18 02:41:00 PDT 1997 Comment-Added: A patch has been committed to 1.2.3 and 1.3a2-dev. >Unformatted: I'm using Apache 1.2 under solaris 2.5.1. I'm puzzled by an odd interaction between the proxy/rewrite modules. In httpd.conf: ProxyRequests On #ProxyRemote http://ss1.bath.ac.uk http://ss1.bath.ac.uk/ #ProxyRemote * http://wwwcache.bath.ac.uk:3128/ In srm.conf: RewriteRule ^/cgi-bin/info2html(.*) http://ss1.bath.ac.uk/cgi-bin/info2html$1 [P ,L] If I then request /cgi-bin/info2html?(info)Top from the server, the logs on ss1.bath.ac.uk show a request for /cgi-bin/info2html?(info)Top as I would expect. However, I need to chain the server on to our main cache. But when I do this by uncommenting the line, ProxyRemote * http://wwwcache.bath.ac.uk:3128/ The request in the access logs for wwwcache are for /cgi-bin/info2html and not http://ss1.bath.ac.uk/cgi-bin/info2html?(info)Top Why are the proxy requests generated by the rewrite rule losing the protocol://host and query strings when other proxy requests are working? Clearly, I can almost achieve what I require by uncommenting the line: ProxyRemote http://ss1.bath.ac.uk http://ss1.bath.ac.uk/ But still the requests show up on ss1.bath.ac.uk as /cgi-bin/info2html without the crucial query string. The rewrite_log consistantly shows the correct rewrites, that is: xxx.bath.ac.uk - - [10/Jun/1997:17:54:15 +0100] [www.bath.ac.uk/sid#7b0c0][rid#96568/initial] (1) go-ahead with proxy request proxy:http://ss1.bath.ac.uk/cgi-bin/info2html?(info)Top [OK] My question is, why is the query string lost? Cheers, Mark Hindess. -- Mark Hindess Tel: (+44) 1225 826485 Computing Services (BUCS),University of Bath,Claverton Down,Bath,BA2 7AY