Received: (qmail 18132 invoked by uid 2012); 30 Sep 1998 17:12:53 -0000
Message-Id: <19980930171253.18131.qmail@hyperreal.org>
Date: 30 Sep 1998 17:12:53 -0000
From: Tony Finch
Reply-To: fanf@demon.net
To: apbugs@hyperreal.org
Subject: r->hostname isn't initialised in sub-requests
X-Send-Pr-Version: 3.2
>Number: 3111
>Category: general
>Synopsis: r->hostname isn't initialised in sub-requests
>Confidential: no
>Severity: serious
>Priority: medium
>Responsible: apache
>State: closed
>Class: sw-bug
>Submitter-Id: apache
>Arrival-Date: Wed Sep 30 10:20:00 PDT 1998
>Last-Modified: Sat Oct 3 07:42:54 PDT 1998
>Originator: fanf@demon.net
>Organization:
>Release: 1.3.2
>Environment:
We're mostly using apache on solaris 2.6 with a bit of 2.5.1 and FreeBSD 2.2.7
>Description:
This problem manifests itself in things like SSIs when you have turned off
UseCanonicalName (pr #2882). It probably also causes difficulties for
mod_rewrite.
>How-To-Repeat:
Set up a server with a bogus ServerName and UseCanonicalName off.
Create a CGI that prints $SERVER_NAME and an shtml document that includes
it. Compare the value of SERVER_NAME from the cgi directly with the
value via SSI.
>Fix:
add the line
rnew->hostname = r->hostname;
to sub_req_lookup_uri() and sub_req_lookup_file()
This fix is due to James Grinter .
>Audit-Trail:
State-Changed-From-To: open-closed
State-Changed-By: rse
State-Changed-When: Sat Oct 3 07:42:54 PDT 1998
State-Changed-Why:
This is now comitted for Apache 1.3.3.
Thanks for your patch and feedback.
>Unformatted:
[In order for any reply to be added to the PR database, ]
[you need to include in the Cc line ]
[and leave the subject line UNCHANGED. This is not done]
[automatically because of the potential for mail loops. ]
[If you do not include this Cc, your reply may be ig- ]
[nored unless you are responding to an explicit request ]
[from a developer. ]
[Reply only with text; DO NOT SEND ATTACHMENTS! ]