Commit 10325b4
committed
Fix integer underflow in ECH innerClientHelloLen parsing
Add bounds check before subtracting WC_AES_BLOCK_SIZE from the
attacker-controlled innerClientHelloLen field in TLSX_ECH_Parse().
Values 0-15 caused a word16 underflow to ~65K, leading to a heap
buffer overflow write via XMEMSET and heap buffer over-read via
wc_AesGcmDecrypt. Return BAD_FUNC_ARG if the field is too small.1 parent af329b3 commit 10325b4
1 file changed
Lines changed: 3 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
13605 | 13605 | | |
13606 | 13606 | | |
13607 | 13607 | | |
| 13608 | + | |
| 13609 | + | |
| 13610 | + | |
13608 | 13611 | | |
13609 | 13612 | | |
13610 | 13613 | | |
| |||
0 commit comments