Skip to content

Commit 7253265

Browse files
committed
DO NOT MERGE keyupdate patch
1 parent 58b153b commit 7253265

File tree

2 files changed

+2
-5
lines changed

2 files changed

+2
-5
lines changed

include/haproxy/quic_conn-t.h

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -145,9 +145,6 @@ enum quic_pkt_type {
145145
#define QUIC_PACKET_PNL_BITMASK 0x03
146146
#define QUIC_PACKET_PN_MAXLEN 4
147147

148-
/* TLS algo supported by QUIC uses a 16-bytes sample for HP. */
149-
#define QUIC_HP_SAMPLE_LEN 16
150-
151148
/*
152149
* 0 1 2 3
153150
* 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1

src/quic_tx.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1994,8 +1994,8 @@ static int qc_do_build_pkt(unsigned char *pos, const unsigned char *end,
19941994
* after PN offset. Thus, pn and payload must be at least 4 bytes long,
19951995
* so that the sample will be extracted as the AEAD tag.
19961996
*/
1997-
if (*pn_len + len < QUIC_PACKET_PN_MAXLEN + QUIC_HP_SAMPLE_LEN) {
1998-
padding_len = QUIC_PACKET_PN_MAXLEN + QUIC_HP_SAMPLE_LEN - (*pn_len + len);
1997+
if (*pn_len + len < QUIC_PACKET_PN_MAXLEN) {
1998+
padding_len = QUIC_PACKET_PN_MAXLEN - *pn_len - (len_frms ? len : 0);
19991999
len += padding_len;
20002000
}
20012001

0 commit comments

Comments
 (0)