httpd-cvs mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From jerenkra...@apache.org
Subject svn commit: r539273 - in /httpd/httpd/branches/2.2.x: CHANGES modules/mappers/mod_alias.c
Date Fri, 18 May 2007 06:00:11 GMT
Author: jerenkrantz
Date: Thu May 17 23:00:10 2007
New Revision: 539273

URL: http://svn.apache.org/viewvc?view=rev&rev=539273
Log:
mod_alias: Accept path components (URL part) in Redirects.  PR 35314.

(Backport of r490142)

Reviewed by: niq, jim, wrowe

Modified:
    httpd/httpd/branches/2.2.x/CHANGES
    httpd/httpd/branches/2.2.x/modules/mappers/mod_alias.c

Modified: httpd/httpd/branches/2.2.x/CHANGES
URL: http://svn.apache.org/viewvc/httpd/httpd/branches/2.2.x/CHANGES?view=diff&rev=539273&r1=539272&r2=539273
==============================================================================
--- httpd/httpd/branches/2.2.x/CHANGES [utf-8] (original)
+++ httpd/httpd/branches/2.2.x/CHANGES [utf-8] Thu May 17 23:00:10 2007
@@ -1,6 +1,9 @@
                                                         -*- coding: utf-8 -*-
 Changes with Apache 2.2.5
 
+  *) mod_alias: Accept path components (URL part) in Redirects.  PR 35314.
+     [Nick Kew]
+
   *) mod_headers: Allow % at the end of a Header value.  PR 36609.
      [Nick Kew, Ruediger Pluem]
 

Modified: httpd/httpd/branches/2.2.x/modules/mappers/mod_alias.c
URL: http://svn.apache.org/viewvc/httpd/httpd/branches/2.2.x/modules/mappers/mod_alias.c?view=diff&rev=539273&r1=539272&r2=539273
==============================================================================
--- httpd/httpd/branches/2.2.x/modules/mappers/mod_alias.c (original)
+++ httpd/httpd/branches/2.2.x/modules/mappers/mod_alias.c Thu May 17 23:00:10 2007
@@ -204,7 +204,10 @@
     if (ap_is_HTTP_REDIRECT(status)) {
         if (!url)
             return "URL to redirect to is missing";
-        if (!use_regex && !ap_is_url(url))
+        /* PR#35314: we can allow path components here;
+         * they get correctly resolved to full URLs.
+         */
+        if (!use_regex && !ap_is_url(url) && (url[0] != '/'))
             return "Redirect to non-URL";
     }
     else {



Mime
View raw message