]> granicus.if.org Git - apache/commitdiff
* mod_cache.c: When 'Vary: *' is sent, do not cache, since revalidation is always...
authorPaul Querna <pquerna@apache.org>
Mon, 6 Jun 2005 16:53:15 +0000 (16:53 +0000)
committerPaul Querna <pquerna@apache.org>
Mon, 6 Jun 2005 16:53:15 +0000 (16:53 +0000)
PR: 16125

git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@180341 13f79535-47bb-0310-9956-ffa450edef68

CHANGES
modules/cache/mod_cache.c

diff --git a/CHANGES b/CHANGES
index 309c8b1f811c7beb5b109d1bddaf65837ffc4de7..e358998d6213fe9023b3c6477224fef345582dc7 100644 (file)
--- a/CHANGES
+++ b/CHANGES
@@ -2,6 +2,9 @@ Changes with Apache 2.1.5
 
   [Remove entries to the current 2.0 section below, when backported]
 
+  *) mod_cache: Fix 'Vary: *' behavior to be RFC compliant. PR 16125. 
+     [Paul Querna]
+
   *) mod_cache: Rename 'generate_name' to 'ap_cache_generate_name'. 
      [Paul Querna]
 
index 4138df72cc68b5b757fa0621f9db29582bd4c33a..4be8970917c6b098e12543cb3f32438ef2eb33f7 100644 (file)
@@ -236,7 +236,7 @@ static int cache_save_filter(ap_filter_t *f, apr_bucket_brigade *in)
     cache_request_rec *cache;
     cache_server_conf *conf;
     char *url = r->unparsed_uri;
-    const char *cc_in, *cc_out, *cl;
+    const char *cc_in, *cc_out, *cl, *vary_out;
     const char *exps, *lastmods, *dates, *etag;
     apr_time_t exp, date, lastmod, now;
     apr_off_t size;
@@ -251,7 +251,9 @@ static int cache_save_filter(ap_filter_t *f, apr_bucket_brigade *in)
      * unless CacheStoreNoStore is active.
      */
     cc_in = apr_table_get(r->headers_in, "Cache-Control");
+    vary_out = apr_table_get(r->headers_out, "Vary");
     if (r->no_cache ||
+        ap_cache_liststr(NULL, vary_out, "*", NULL) ||
         (!conf->store_nostore &&
          ap_cache_liststr(NULL, cc_in, "no-store", NULL))) {
         ap_remove_output_filter(f);