From: Frédéric Lécaille Date: Mon, 6 Feb 2023 10:54:07 +0000 (+0100) Subject: MINOR: quic: Update version_information transport parameter to draft-14 X-Git-Tag: v2.8-dev4~36 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=b7a406ac34990fdde180ce56491a6261e6c90897;p=thirdparty%2Fhaproxy.git MINOR: quic: Update version_information transport parameter to draft-14 This is necessary to make our stack negotiate the QUIC versions with clients. (See https://author-tools.ietf.org/iddiff?url1=draft-ietf-quic-version-negotiation-13&url2=draft-ietf-quic-version-negotiation-14&difftype=--html) Must be backported to 2.7. --- diff --git a/include/haproxy/quic_tp-t.h b/include/haproxy/quic_tp-t.h index 24859e73e6..29f993b41e 100644 --- a/include/haproxy/quic_tp-t.h +++ b/include/haproxy/quic_tp-t.h @@ -63,7 +63,7 @@ struct tp_version_information { #define QUIC_TP_ACTIVE_CONNECTION_ID_LIMIT 0x0e #define QUIC_TP_INITIAL_SOURCE_CONNECTION_ID 0x0f #define QUIC_TP_RETRY_SOURCE_CONNECTION_ID 0x10 -#define QUIC_TP_DRAFT_VERSION_INFORMATION 0xff73db +#define QUIC_TP_VERSION_INFORMATION 0x11 /* * These defines are not for transport parameter type, but the maximum accepted value for diff --git a/src/quic_tp.c b/src/quic_tp.c index e763757276..ae013613aa 100644 --- a/src/quic_tp.c +++ b/src/quic_tp.c @@ -319,7 +319,7 @@ static int quic_transport_param_decode(struct quic_transport_params *p, if (!quic_dec_int(&p->active_connection_id_limit, buf, end)) return 0; break; - case QUIC_TP_DRAFT_VERSION_INFORMATION: + case QUIC_TP_VERSION_INFORMATION: if (!quic_transport_param_dec_version_info(&p->version_information, buf, *buf + len, server)) return 0; @@ -435,7 +435,7 @@ static int quic_transport_param_enc_version_info(unsigned char **buf, tp_len = sizeof chosen_version->num + quic_versions_nb * sizeof(uint32_t); if (!quic_transport_param_encode_type_len(buf, end, - QUIC_TP_DRAFT_VERSION_INFORMATION, + QUIC_TP_VERSION_INFORMATION, tp_len)) return 0;