diff options
author | Szymon Heidrich | 2023-03-18 10:25:52 +0100 |
---|---|---|
committer | Greg Kroah-Hartman | 2023-03-30 12:49:06 +0200 |
commit | 83de34967473ed31d276381373713cc2869a42e5 (patch) | |
tree | 00e8a6eeeea7fc5d3b397744e0de7bef14ca1cd7 /drivers/regulator/as3722-regulator.c | |
parent | 5fc2c4e311a9341a2b0e044ab5f33afa37b56226 (diff) |
net: usb: lan78xx: Limit packet length to skb->len
[ Upstream commit 7f247f5a2c18b3f21206cdd51193df4f38e1b9f5 ]
Packet length retrieved from descriptor may be larger than
the actual socket buffer length. In such case the cloned
skb passed up the network stack will leak kernel memory contents.
Additionally prevent integer underflow when size is less than
ETH_FCS_LEN.
Fixes: 55d7de9de6c3 ("Microchip's LAN7800 family USB 2/3 to 10/100/1000 Ethernet device driver")
Signed-off-by: Szymon Heidrich <szymon.heidrich@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Signed-off-by: Sasha Levin <sashal@kernel.org>
Diffstat (limited to 'drivers/regulator/as3722-regulator.c')
0 files changed, 0 insertions, 0 deletions