From: Alex Rousskov Date: Tue, 16 Mar 2021 15:45:11 +0000 (-0400) Subject: Limit HeaderLookupTable_t::lookup() to BadHdr and specific IDs X-Git-Tag: SQUID_4_15~9 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=b1c37c9e7b30d0efb5e5ccf8200f2a646b9c36f8;p=thirdparty%2Fsquid.git Limit HeaderLookupTable_t::lookup() to BadHdr and specific IDs --- diff --git a/src/http/RegisteredHeaders.cc b/src/http/RegisteredHeaders.cc index 6b420638e6..348a1bb821 100644 --- a/src/http/RegisteredHeaders.cc +++ b/src/http/RegisteredHeaders.cc @@ -37,7 +37,7 @@ HeaderTableRecord::HeaderTableRecord(const char *n, HdrType theId, HdrFieldType const HeaderTableRecord& HeaderLookupTable_t::lookup (const char *buf, const std::size_t len) const { const HeaderTableRecord *r = HttpHeaderHashTable::lookup(buf, len); - if (!r) + if (!r || r->id == Http::HdrType::OTHER) return BadHdr; return *r; }