]> git.ipfire.org Git - thirdparty/haproxy.git/commit
BUG/MINOR: http-compression: lookup Cache-Control in the response, not the request
authorWilly Tarreau <w@1wt.eu>
Sat, 5 Jan 2013 15:20:35 +0000 (16:20 +0100)
committerWilly Tarreau <w@1wt.eu>
Sat, 5 Jan 2013 15:31:58 +0000 (16:31 +0100)
commit56e9ffa6a6da0227776f278afb9f7dafa1963606
tree5b21423c204f57315f1c5e03780c24c8bb048861
parent869948b0623c50d5ab10f09f4b19c391ec67a942
BUG/MINOR: http-compression: lookup Cache-Control in the response, not the request

As stated in both RFC2616 and the http-bis drafts, Cache-Control:
no-transform must be looked up in the response since we're modifying
the response. However, its presence in the request is irrelevant to
any changes in the response :

  7.2.1.6. no-transform
   The "no-transform" request directive indicates that an intermediary
   (whether or not it implements a cache) MUST NOT change the Content-
   Encoding, Content-Range or Content-Type request header fields, nor
   the request representation.

  7.2.2.9. no-transform
   The "no-transform" response directive indicates that an intermediary
   (regardless of whether it implements a cache) MUST NOT change the
   Content-Encoding, Content-Range or Content-Type response header
   fields, nor the response representation.

Note: according to the specs, we're supposed to emit the following
response header :

  Warning: 214 transformation applied

However no other product seems to do it, so the effect on user agents
is unclear.
src/proto_http.c