header value RFC compliant like the case of an
Expires time in the past: allow to overwrite the
non-caching decision using CacheStoreExpired and
respect Cache-Control "max-age" and "s-maxage".
Backport of r1833876 from trunk.
Submitted by: rjung
Reviewed by: rjung, ylavic, rpluem
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/branches/2.4.x@
1834241 13f79535-47bb-0310-9956-
ffa450edef68
-*- coding: utf-8 -*-
Changes with Apache 2.4.34
+ *) mod_cache: Handle case of an invalid Expires header value RFC compliant
+ like the case of an Expires time in the past: allow to overwrite the
+ non-caching decision using CacheStoreExpired and respect Cache-Control
+ "max-age" and "s-maxage". [Rainer Jung]
+
*) mod_xml2enc: Fix forwarding of error metadata/responses. PR 62180.
[Micha Lenk <micha lenk.info>, Yann Ylavic]
svn merge -c 1833827 ^/httpd/httpd/trunk .
+1: covener, jim, rjung
- *) mod_cache: Handle case of invalid Expires header RFC compliant
- like the case of an Expires time in the past.
- So allow to overwrite the non-caching decision
- using "CacheStoreExpired" and respect Cache-Control
- "max-age" and "s-maxage".
- trunk patch: http://svn.apache.org/r1833876
- 2.4.x patch: trunk works (needs CHANGES in 2.4)
- svn merge -c 1833876 ^/httpd/httpd/trunk .
- +1: rjung, ylavic, rpluem
-
PATCHES PROPOSED TO BACKPORT FROM TRUNK:
[ New proposals should be added at the end of the list ]
if (reason) {
/* noop */
}
- else if (exps != NULL && exp == APR_DATE_BAD) {
- /* if a broken Expires header is present, don't cache it */
+ else if (!control.s_maxage && !control.max_age && !dconf->store_expired
+ && exps != NULL && exp == APR_DATE_BAD) {
+ /* if a broken Expires header is present, don't cache it
+ * Unless CC: s-maxage or max-age is present
+ */
reason = apr_pstrcat(p, "Broken expires header: ", exps, NULL);
}
else if (!control.s_maxage && !control.max_age