diff options
| author | 2026-09-21 23:41:16 +0300 | |
|---|---|---|
| committer | 2026-10-14 11:56:35 +0300 | |
| commit | 56fe437aef2dc9bd37ad2b0abd9404a65d69e102 (patch) | |
| tree | 733cc2afecd00c51795d48a184407ff0c3d10628 /scripts/Makefile.thinlto | |
| parent | wifi: iwlwifi: mld: don't use bss_conf in NAN (diff) | |
wifi: iwlwifi: fw: fix integer overflow in INI dump size calc
The INI debug dump get_size handlers compute the region size as
hdr_size + ranges * (size + sizeof(range)) using u32 arithmetic.
Both the per-range size and the number of ranges originate from
debug TLVs with no upper bound, so the multiplication and additions
can overflow u32. A small value passes the
size < sizeof(*header) check in iwl_dump_ini_mem_prep().
Add the size computation in each handler using
check_add_overflow()/check_mul_overflow() and return 0 when the
result would overflow. For the block handler the variable per-pair
sizes are summed with check_add_overflow() before computing size,
since that accumulation can overflow on its own.
Signed-off-by: Shahar Tzarfati <shahar.tzarfati@intel.com>
Assisted-by: GitHub-Copilot:claude-opus-4-8
Link: https://patch.msgid.link/20260921233730.0644f76cd8af.Id0d26b11fcdb33a5eff7824343caa6dc23385fd5@changeid
Signed-off-by: Miri Korenblit <miriam.rachel.korenblit@intel.com>
Diffstat (limited to 'scripts/Makefile.thinlto')
0 files changed, 0 insertions, 0 deletions
