]> git.ipfire.org Git - thirdparty/squid.git/commit
Do not escape malformed URI twice when sending ICP errors (#2374)
authorJoshua Rogers <megamansec@gmail.com>
Tue, 10 Feb 2026 19:58:49 +0000 (19:58 +0000)
committerSquid Anubis <squid-anubis@squid-cache.org>
Wed, 11 Feb 2026 01:37:01 +0000 (01:37 +0000)
commit61268b075cdf193ed98a1742dffbf0773e4a4f08
tree81f38cc4e15175107d727904ff67e163a63b7593
parent52c60bb7846a358326ce7232b0b8c035381cd164
Do not escape malformed URI twice when sending ICP errors (#2374)

In this context, escaping escaped URI always produces incorrect URI
because `%` character in the escaped URI gets escaped again. Feeding the
result of the first rfc1738_escape() call to the second call is also
dangerously wrong because the result of the first call gets invalidated
during the second call.

No other cases of such "chained" rfc1738_escape() calls were found.

Broken since 2002 commit e6ccf245.
src/icp_v2.cc