]> git.ipfire.org Git - thirdparty/squid.git/commit
Re-fix parsing of legacy url_rewrite_program responses (#2446) auto master
authorAlex Rousskov <rousskov@measurement-factory.com>
Mon, 22 Jun 2026 20:10:29 +0000 (20:10 +0000)
committerSquid Anubis <squid-anubis@squid-cache.org>
Mon, 22 Jun 2026 20:33:04 +0000 (20:33 +0000)
commit0b8e893e52b278b87f9ade137c2ddf65195ce028
tree0d92a317ecfa858c301f510b3321de81424a7c33
parentacdf34ea285065565e91f2e2f0b5c09e86ae0446
Re-fix parsing of legacy url_rewrite_program responses (#2446)

Legacy helper responses start with a URL instead of `OK rewrite_url=...`
and such. 2016 commit ddc77a2e introduced two bugs when handling legacy
responses:

* Response parsing code triggered MemBuf assertions when 0-terminating
  the parsing buffer for certain URLs. The bug affected legacy helper
  responses with and without space characters.

* Squid code attempted to accept/use helper-returned URLs with embedded
  space character(s), despite a WARNING implying that the post-space
  characters are not going to become a part of the new URL.

----

This change resurrects recent commit bb854bb9 that was accidentally
reverted by commit ec328cf16 during pull request merging by Anubis.
CONTRIBUTORS
src/redirect.cc