[Varnish] #1816: Return 304 for If-None-Match on weak ETag match (cache hit)

Varnish varnish-bugs at varnish-cache.org
Thu Nov 12 17:48:27 CET 2015


#1816: Return 304 for If-None-Match on weak ETag match (cache hit)
---------------------------------------------+----------------------
 Reporter:  teohhanhui                       |       Type:  defect
   Status:  new                              |   Priority:  normal
Milestone:                                   |  Component:  varnishd
  Version:  4.0.3                            |   Severity:  normal
 Keywords:  304 if-none-match weak etag hit  |
---------------------------------------------+----------------------
 Currently when the client sends a request with weak ETag and it matches,
 Varnish returns response with 200 status code on cache hit.

 But it should actually return 304 just like with strong ETag.


 See https://tools.ietf.org/html/rfc7232#section-3.2

 > 3.2.  If-None-Match
 > A recipient MUST use the weak comparison function when comparing entity-
 tags for If-None-Match (Section 2.3.2), since weak entity-tags can be used
 for cache validation even if there have been changes to the representation
 data.

-- 
Ticket URL: <https://www.varnish-cache.org/trac/ticket/1816>
Varnish <https://varnish-cache.org/>
The Varnish HTTP Accelerator



More information about the varnish-bugs mailing list