]> git.ipfire.org Git - thirdparty/haproxy.git/commit
MINOR: cache: Change hash function in default normalizer used in case of "vary"
authorRemi Tricot-Le Breton <rlebreton@haproxy.com>
Thu, 31 Aug 2023 13:58:08 +0000 (15:58 +0200)
committerWilliam Lallemand <wlallemand@haproxy.org>
Wed, 6 Sep 2023 14:11:31 +0000 (16:11 +0200)
commite03d060aa308e3ba51aeb60b677425eab3d195bd
tree8a01633b8f2f5fee4a827739d24e1aaee9fad0f9
parent7a71801af633941f3b2e7d5649f70f98a0da7904
MINOR: cache: Change hash function in default normalizer used in case of "vary"

When building the secondary signature for cache entries when vary is
enabled, the referer part of the signature was a simple crc32 of the
first referer header.
This patch changes it to a 64bits hash based of xxhash algorithm with a
random seed built during init. This will prevent "malicious" hash
collisions between entries of the cache.
include/haproxy/http_ana-t.h
src/cache.c