]> git.ipfire.org Git - thirdparty/kernel/linux.git/commit
net: mana: Validate the packet length reported by the NIC
authorDexuan Cui <decui@microsoft.com>
Thu, 2 Jul 2026 04:12:36 +0000 (21:12 -0700)
committerPaolo Abeni <pabeni@redhat.com>
Thu, 9 Jul 2026 08:35:54 +0000 (10:35 +0200)
commit2e2a83b4998af4384e677d3b2ac08565274279bf
tree98f5e6830f439007b53bdce4ee00bf02b8da7837
parentf4ef35efbb49527293309f668ea73ec5de9b8e7a
net: mana: Validate the packet length reported by the NIC

Validate the packet length reported in the RX CQE before passing it
to skb processing. The CQE is supplied by the NIC device and should
not be blindly trusted.

Cc: stable@vger.kernel.org
Reviewed-by: Haiyang Zhang <haiyangz@microsoft.com>
Signed-off-by: Dexuan Cui <decui@microsoft.com>
Fixes: ca9c54d2d6a5 ("net: mana: Add a driver for Microsoft Azure Network Adapter (MANA)")
Link: https://patch.msgid.link/20260702041237.617719-2-decui@microsoft.com
Signed-off-by: Paolo Abeni <pabeni@redhat.com>
drivers/net/ethernet/microsoft/mana/mana_en.c