net: usb: cdc_ncm: add ndpoffset to NDP32 nframes bounds check
Linux
Affected versions
| Product | Affected | Fixed in |
|---|---|---|
| Linux Linux |
|
Linux
| Product | Affected | Fixed in |
|---|---|---|
| Linux Linux |
|
≥ 0fa81b304a7973a499f844176ca031109487dd31 · < 77914255155e68a20aa41175edeecf8121dac391| No fix yet |
| Linux Linux |
|
|
In the Linux kernel, the following vulnerability has been resolved:
net: usb: cdc_ncm: add ndpoffset to NDP32 nframes bounds check
The same bounds-check bug fixed for NDP16 in the previous patch also exists in cdc_ncm_rx_verify_ndp32(). The DPE array size is validated against the total skb length without accounting for ndpoffset, allowing out-of-bounds reads when the NDP32 is placed near the end of the NTB.
Add ndpoffset to the nframes bounds check and use struct_size_t() to express the NDP-plus-DPE-array size more clearly.
Compile-tested only.
From the CVE record · Linux
The cdc_ncm NDP32 bounds check does not account for the NDP offset. This can allow an out-of-bounds read when an NDP32 is placed near the end of an NTB. The input does not specify whether exploitation requires network or local access, authentication, or user interaction.
Anyone running the Linux kernel should check their version; affected versions are not specified.