]> git.kaiwu.me - haproxy.git/commit
BUG/MINOR: jwe: Avoid buffer overflow in fake cek (RSA1.5)
authorRemi Tricot-Le Breton <rlebreton@haproxy.com>
Wed, 30 Sep 2026 08:27:13 +0000 (10:27 +0200)
committerWilly Tarreau <w@1wt.eu>
Wed, 30 Sep 2026 14:11:24 +0000 (16:11 +0200)
commit29ac6640eaf013086a492c1ab65f648e4098e57e
treeb8ec2b513fb9be0c3bbb26bb864dfd8347e93995
parent623789ef276986795f1fdfb2b8e523a349a3acb7
BUG/MINOR: jwe: Avoid buffer overflow in fake cek (RSA1.5)

In commit 1a5a333 "BUG/MEDIUM: jwe: substitute random CEK on RSA1_5
decryption failure per RFC 7516 #11.5" we fill a fake CEK with random
data to avoid timing attacks but the size of the buffer was never
checked. If we happened to have a too little bufsize (less than 64
bytes) we could have out of bounds accesses.

This issue was found by Dmitri Kaslov.

This patch should be backported to 3.4.
src/jwe.c