]> granicus.if.org Git - apache/commitdiff
*) mod_cache_socache: Fix caching of empty headers up to carriage return.
authorGraham Leggett <minfrin@apache.org>
Fri, 16 Feb 2018 13:34:35 +0000 (13:34 +0000)
committerGraham Leggett <minfrin@apache.org>
Fri, 16 Feb 2018 13:34:35 +0000 (13:34 +0000)
     trunk patch: http://svn.apache.org/r1824343
     2.4.x patch: trunk works (modulo CHANGES)
     +1: ylavic, rpluem, minfrin

git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/branches/2.4.x@1824475 13f79535-47bb-0310-9956-ffa450edef68

CHANGES
STATUS
modules/cache/mod_cache_socache.c

diff --git a/CHANGES b/CHANGES
index edcf422001e8c3cbd4e8dc4b6bf253f38ce10198..14b8cc6eb5b9698615029a42c901f35a26ff4e68 100644 (file)
--- a/CHANGES
+++ b/CHANGES
@@ -1,6 +1,9 @@
                                                          -*- coding: utf-8 -*-
 Changes with Apache 2.4.30
 
+  *) mod_cache_socache: Fix caching of empty headers up to carriage return.
+     [Yann Ylavic]
+
   *) core: For consistency, ensure that read lines are NUL terminated on any
      error, not only on buffer full.  [Yann Ylavic]
 
diff --git a/STATUS b/STATUS
index ff3bcaea8d96f27e3e5547b2016dd746c3d4f125..9ec4ff6acf0119528a80ac10463b8348a940cf44 100644 (file)
--- a/STATUS
+++ b/STATUS
@@ -118,10 +118,6 @@ RELEASE SHOWSTOPPERS:
 PATCHES ACCEPTED TO BACKPORT FROM TRUNK:
   [ start all new proposals below, under PATCHES PROPOSED. ]
 
-  *) mod_cache_socache: Fix caching of empty headers up to carriage return.
-     trunk patch: http://svn.apache.org/r1824343
-     2.4.x patch: trunk works (modulo CHANGES)
-     +1: ylavic, rpluem, minfrin
 
 
 PATCHES PROPOSED TO BACKPORT FROM TRUNK:
index 11e950285d3533f6829129e3b65de4f937d14be3..0d76760c5bae7f78fd25a8a91e34849030366bab 100644 (file)
@@ -213,7 +213,8 @@ static apr_status_t read_table(cache_handle_t *handle, request_rec *r,
                         "Premature end of cache headers.");
                 return APR_EGENERAL;
             }
-            while (apr_isspace(buffer[colon])) {
+            /* Do not go past the \r from above as apr_isspace('\r') is true */
+            while (apr_isspace(buffer[colon]) && (colon < *slider)) {
                 colon++;
             }
             apr_table_addn(table, apr_pstrndup(r->pool, (const char *) buffer