httpd-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Ruediger Pluem <>
Subject Re: svn commit: r490142 - /httpd/httpd/trunk/modules/mappers/mod_alias.c
Date Tue, 26 Dec 2006 10:29:35 GMT

On 12/26/2006 03:49 AM, Nick Kew wrote:
> On 25 Dec 2006, at 22:59, Ruediger Pluem wrote:
>>> -        if (!use_regex && !ap_is_url(url))
>>> +        /* PR#35314: we can allow path components here;
>>> +         * they get correctly resolved to full URLs.
>> Where? A quick check shows that the resulting Location header has  no
>> scheme and host in front.
>> AFAICT this violates 14.30 of RFC2616 as the value of a Location 
>> header must be an absoluteURI
>> or better absolute-URI as defined in 4.3 of RFC3986.
> What kind of a quick check?  I ran a case with leading slash, both from
> httpd.conf and .htaccess, expecting to see broken Location headers which

That was the same I did, but with different results (see below).

> I was then going to fix at the point where they're generated (which  can't
> be at config-time because we don't always have a server name at
> that point).  But it returned full, valid and correct Location headers
> to the client without me doing anything.  Hence the trivial change
> and comment.

That is very strange. See the results below I got from the following
configuration (trunk, r490277):


Servername localhost
Redirect /zw /blub


telnet 80
Connected to
Escape character is '^]'.
GET /zw HTTP/1.0

HTTP/1.1 302 Found
Date: Tue, 26 Dec 2006 10:23:33 GMT
Server: Apache/2.3.0-dev (Unix) DAV/2 mod_ssl/2.3.0-dev OpenSSL/0.9.6g
Location: /blub
Content-Length: 189
Connection: close
Content-Type: text/html; charset=iso-8859-1

<title>302 Found</title>
<p>The document has moved <a href="/blub">here</a>.</p>
Connection closed by foreign host.

So I get an invalid Location header, plus I am not sure which part of the code
should transform this in an absolute-URI



View raw message