1. 30 Nov, 2016 1 commit
  2. 24 Oct, 2016 2 commits
  3. 20 Oct, 2016 1 commit
  4. 16 Jun, 2016 2 commits
  5. 25 May, 2016 1 commit
  6. 11 May, 2016 1 commit
  7. 20 Apr, 2016 1 commit
  8. 07 Apr, 2016 1 commit
  9. 05 Apr, 2016 3 commits
  10. 31 Mar, 2016 1 commit
  11. 30 Mar, 2016 1 commit
  12. 25 Mar, 2016 1 commit
  13. 23 Mar, 2016 1 commit
  14. 18 Mar, 2016 1 commit
    • Dridi Boukelmoune's avatar
      Add a miniobj macro for taking over pointer · c58e98d6
      Dridi Boukelmoune authored
      There's a recurring pattern throughout the code base of taking over
      a reference (by nulling the original) essentially when resources are
      freed. Instead of repeating this anti dangling pointers measure, it
      can be wrapped in a documenting utility macro.
      c58e98d6
  15. 16 Mar, 2016 1 commit
    • Pål Hermunn Johansen's avatar
      Proper handling of duplicate headers on IMS headers merge · 34d0fe4a
      Pål Hermunn Johansen authored
      With this patch we properly handle duplicated headers when using http
      conditionals (dubbed backend IMS in Varnish). If the backend first
      sends the following:
      
      foo: a
      foo: b
      
      the backend forwards these as is. If then the objects grace period
      ends, but the object is not evicted from the cached, varnish will send
      a if-none-match header to the backend. The backend can then reply with
      a status 304 Not Modified. In this case the backend can send new 'foo'
      headers, or not. Varnish then has to react accordingly by either
      sending the original set of 'foo' headers, or the new set of 'foo'
      headers. The attached test checks both cases of backend behavior.
      
      Ref: #1879
      34d0fe4a
  16. 10 Mar, 2016 1 commit
    • Pål Hermunn Johansen's avatar
      Remove assert in shared memory · f4b2cb9c
      Pål Hermunn Johansen authored
      Even though the shared memory log should always have only one writer,
      the varnish process, this is not enforced by the kernel through access
      rights. For this reason, the line
      
           assert(b->vsc->vcls > 0);
      
      could crash Varnish if a process decided to write to the shared memory
      log. Now this bad behavior will just affect other readers of the
      shared memory log, and not the varnish process itself.
      f4b2cb9c
  17. 22 Feb, 2016 1 commit
  18. 25 Jan, 2016 2 commits
    • Poul-Henning Kamp's avatar
      Add a final backstop, so we absolutely 100% certainly do not · 9c490b6c
      Poul-Henning Kamp authored
      try to delete a objhead while it still has a waiting list,
      by forcing the last ref holder to rush the WL.
      
      Since the hasher owns the refcounts on objhead, we cannot just
      mingle req and objcore refcounts.
      
      Fortunately we don't need to add another refcounter, because all
      we really care about is the wl being empty when we drop the last
      ref.
      
      The wl/hsh_rush() mechanism will work differently with different
      thread-scheduling schenarios, and I cannot definitively rule out
      that we can drop the last ref on an oh, while there are still req's
      on the waiting list.
      
      Given that, and the existence proof in ticket #1823's race, this
      might have been the indicated memory-trampler.
      
      Conflicts:
      	bin/varnishd/cache/cache_hash.c
      9c490b6c
    • Poul-Henning Kamp's avatar
      d418ffab
  19. 11 Jan, 2016 1 commit
  20. 24 Dec, 2015 1 commit
  21. 21 Dec, 2015 1 commit
  22. 09 Dec, 2015 1 commit
  23. 27 Nov, 2015 1 commit
  24. 19 Oct, 2015 2 commits
    • Lasse Karstensen's avatar
      Skip headers on errors. · 6b2cc809
      Lasse Karstensen authored
      This didn't make any sense and should never have been commited.
      6b2cc809
    • Lasse Karstensen's avatar
      Allow invalid headers in 304 backend responses. · ef6f15e5
      Lasse Karstensen authored
      Allow the backend server to send headers lacking ":"/colon in
      them when responding to a conditional request yielding a 304 response.
      
      In master/4.1 such responses are aborted as invalid. The backend is
      clearly not feeling well.
      
      Since we've accepted it nicely for 200 responses so far in Varnish 4.0,
      continue that trend also for 304s.
      
      Fixes: #1598
      ef6f15e5
  25. 14 Sep, 2015 2 commits
  26. 14 Jul, 2015 4 commits
    • Nils Goroll's avatar
      Add a regression test for #1762 · 9bffd9ea
      Nils Goroll authored
      Further investigating into root cause scenarios resulted in the
      following insights:
      
      * the bad vxid must have got into vtx->key.vxid by way of
        `vtx_parse_link`
      
      * which is only called for `SLT_Begin` (`vtx_scan_begin()`) and
        `SLT_Link` (`vtx_scan_link()`)
      
      (actually this was known before, but I am now confident that these are
      the only cases)
      
      There is no case in the code as of 4.0.3 release where `SLT_Begin` is
      emitted with an unmasked vxid, so the issue must be root casue in an
      `SLT_Link` link record.
      
      In both cases where unmasked vxids are emitted for `SLT_Link`, the id
      comes directly from `VXID_Get()`:
      
      * `cache_fetch.c`
      
        wid = VXID_Get(&wrk->vxid_pool);
        VSLb(bo->vsl, SLT_Link, "bereq %u retry", wid);
      
      * `cache_req_fsm.c`
      
        wid = VXID_Get(&wrk->vxid_pool);
        // XXX: ReqEnd + ReqAcct ?
        VSLb_ts_req(req, "Restart", W_TIM_real(wrk));
        VSLb(req->vsl, SLT_Link, "req %u restart", wid);
      
      So unless I have overseen anything significant, the root cause must
      have been a vxid spill, which was fixed with
      0dd8c0b8 (master) /
      171f3ac5 (4.0)
      
      `VXID()` masking would have avoided the issue to surface.
      
      This insight is consistent with two observations:
      
      * the issue only surfaced after `varnishd` running for longer periods
        of time
      
      * the issue didn't go away after a restart of the vsl client, a
        `varnishd` restart was required
      
      This gives confidence that the issue has really been understood
      completely and that the root cause has been fixed.
      9bffd9ea
    • Nils Goroll's avatar
      dont use VSL_Error as a format string · 8e3f9192
      Nils Goroll authored
      8e3f9192
    • Nils Goroll's avatar
      Assert that literal vxids we parse never have the client/server bit set · 9119bfd6
      Nils Goroll authored
      This is an additional safeguard against regressions of #1762
      9119bfd6
    • Nils Goroll's avatar
      vtc: allow VSL arguments in logexpect · a373d26c
      Nils Goroll authored
      a373d26c
  27. 13 Jul, 2015 2 commits
  28. 19 Jun, 2015 2 commits