Re: [PATCH net v3] net: usb: cdc_ncm: fix out-of-bounds read of chained NDP32 offset
From: patchwork-bot+netdevbpf
Date: Tue Nov 17 2026 - 07:20:22 EST
Hello:
This patch was applied to netdev/net-next.git (main)
by Paolo Abeni <pabeni@xxxxxxxxxx>:
On Thu, 12 Nov 2026 08:22:09 +0000 you wrote:
> The NDP offset read from dwNextNdpIndex on the 32-bit NTB (NDP32)
> path is not checked for a negative value before use. A
> device-supplied dwNextNdpIndex in the 0xFFFFFFF0-0xFFFFFFFF range
> sign-converts to a small negative int. cdc_ncm_rx_verify_ndp32()'s
> existing bounds check then double-wraps: promoting the negative int
> to size_t first produces a huge value, and adding
> sizeof(struct usb_cdc_ncm_ndp32) to that wraps it back down to a
> small value that passes the "> skb_in->len" check, causing an
> out-of-bounds read of up to 16 bytes before the skb's data buffer.
>
> [...]
Here is the summary with links:
- [net,v3] net: usb: cdc_ncm: fix out-of-bounds read of chained NDP32 offset
https://git.kernel.org/netdev/net-next/c/c1824744b3b6
You are awesome, thank you!
--
Deet-doot-dot, I am a bot.
https://korg.docs.kernel.org/patchwork/pwbot.html