]> git.kaiwu.me - haproxy.git/commit
MINOR: quic: do not use quic_newcid_from_hash64 on BE side
authorAmaury Denoyelle <adenoyelle@haproxy.com>
Mon, 10 Nov 2025 13:38:45 +0000 (14:38 +0100)
committerAmaury Denoyelle <adenoyelle@haproxy.com>
Mon, 17 Nov 2025 09:11:04 +0000 (10:11 +0100)
commit8720130cc7052ac1c5931fff8f4b49a38eab9668
tree4006b32f619ef17abe2747b87ca250ba63fca88c
parentfc6e3e9081906962535946a4fc3e4b506f93ee4f
MINOR: quic: do not use quic_newcid_from_hash64 on BE side

quic_newcid_from_hash64 is an external callback. If defined, it serves
as a CID method generation, as an alternative to the default random
implementation.

This mechanism was not correctly implemented on the backend side.
Indeed, <hash64> quic_conn member is only setted for frontend
connections. The simplest solution would be to properly define it also
for backend ones. However, quic_newcid_from_hash64 derivation is really
only useful for the frontend side for now. Thus, this patch disables
using it on the backend side in favor of the default random generator.

To implement this, quic_cid_generate() is splitted in two functions, for
both methods of CIDs generation. This is the responsibility of the
caller to select the proper method. On backend side, only random
implementation is now used.
include/haproxy/quic_cid.h
src/quic_cid.c
src/quic_conn.c
src/quic_rx.c