Commit 65d0880
committed
tls: fix TLSX_TCA_GetSize word16 overflow (F-2131)
Mirror the TLSX_SNI_GetSize pattern: accumulate into a word32 and
return 0 when the aggregate size exceeds WOLFSSL_MAX_16BIT so large
idSz values or many TCA entries no longer silently wrap to a small
value that undersizes the TLSX_TCA_Write output buffer.1 parent 2f51508 commit 65d0880
1 file changed
Lines changed: 15 additions & 4 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
2945 | 2945 | | |
2946 | 2946 | | |
2947 | 2947 | | |
2948 | | - | |
| 2948 | + | |
2949 | 2949 | | |
2950 | 2950 | | |
2951 | 2951 | | |
| |||
2963 | 2963 | | |
2964 | 2964 | | |
2965 | 2965 | | |
| 2966 | + | |
| 2967 | + | |
| 2968 | + | |
| 2969 | + | |
2966 | 2970 | | |
2967 | 2971 | | |
2968 | | - | |
| 2972 | + | |
2969 | 2973 | | |
2970 | 2974 | | |
2971 | 2975 | | |
| |||
14800 | 14804 | | |
14801 | 14805 | | |
14802 | 14806 | | |
14803 | | - | |
14804 | | - | |
| 14807 | + | |
| 14808 | + | |
| 14809 | + | |
| 14810 | + | |
| 14811 | + | |
| 14812 | + | |
| 14813 | + | |
| 14814 | + | |
| 14815 | + | |
14805 | 14816 | | |
14806 | 14817 | | |
14807 | 14818 | | |
| |||
0 commit comments