linux-uconsole/drivers/net/usb
Marcin Kozlowski d90df6da50 net: usb: aqc111: Fix out-of-bounds accesses in RX fixup
[ Upstream commit afb8e24652 ]

aqc111_rx_fixup() contains several out-of-bounds accesses that can be
triggered by a malicious (or defective) USB device, in particular:

 - The metadata array (desc_offset..desc_offset+2*pkt_count) can be out of bounds,
   causing OOB reads and (on big-endian systems) OOB endianness flips.
 - A packet can overlap the metadata array, causing a later OOB
   endianness flip to corrupt data used by a cloned SKB that has already
   been handed off into the network stack.
 - A packet SKB can be constructed whose tail is far beyond its end,
   causing out-of-bounds heap data to be considered part of the SKB's
   data.

Found doing variant analysis. Tested it with another driver (ax88179_178a), since
I don't have a aqc111 device to test it, but the code looks very similar.

Signed-off-by: Marcin Kozlowski <marcinguy@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Signed-off-by: Sasha Levin <sashal@kernel.org>
2022-04-20 09:23:23 +02:00
..
aqc111.c net: usb: aqc111: Fix out-of-bounds accesses in RX fixup 2022-04-20 09:23:23 +02:00
aqc111.h
asix.h
asix_common.c
asix_devices.c
ax88172a.c
ax88179_178a.c net: usb: ax88179_178a: Fix out-of-bounds accesses in RX fixup 2022-02-16 12:54:28 +01:00
catc.c
cdc-phonet.c
cdc_eem.c net: cdc_eem: fix tx fixup skb leak 2021-06-23 14:42:47 +02:00
cdc_ether.c USB: zaurus: support another broken Zaurus 2022-03-02 11:42:47 +01:00
cdc_mbim.c net: usb: cdc_mbim: avoid altsetting toggling for Telit FN990 2022-03-08 19:09:30 +01:00
cdc_ncm.c CDC-NCM: avoid overflow in sanity checking 2022-03-02 11:42:47 +01:00
cdc_subset.c
ch9200.c
cx82310_eth.c
dm9601.c
gl620a.c
hso.c usb: hso: remove the bailout parameter 2021-10-06 15:56:02 +02:00
huawei_cdc_ncm.c
int51x1.c
ipheth.c ipheth: fix EOVERFLOW in ipheth_rcvbulk_callback 2022-02-05 12:37:56 +01:00
kalmia.c
kaweth.c
Kconfig lan78xx: select CRC32 2021-10-27 09:56:48 +02:00
lan78xx.c net: usb: lan78xx: add Allied Telesis AT29M2-AF 2021-12-29 12:25:53 +01:00
lan78xx.h
lg-vl600.c
Makefile
mcs7830.c net: mcs7830: handle usb read errors properly 2022-01-27 10:54:04 +01:00
net1080.c
pegasus.c net: usb: pegasus: Do not drop long Ethernet frames 2022-01-05 12:40:30 +01:00
pegasus.h
plusb.c
qmi_wwan.c net: usb: qmi_wwan: Add support for Dell DW5829e 2022-02-23 12:01:06 +01:00
r8152.c r8152: fix writing USB_BP2_EN 2021-08-26 08:35:51 -04:00
rndis_host.c rndis_host: support Hytera digital radios 2022-01-11 15:25:01 +01:00
rtl8150.c
sierra_net.c
smsc75xx.c net: usb: fix possible use-after-free in smsc75xx_bind 2021-06-23 14:42:46 +02:00
smsc75xx.h
smsc95xx.c smsc95xx: Ignore -ENODEV errors when device is unplugged 2022-03-23 09:13:29 +01:00
smsc95xx.h
sr9700.c sr9700: sanity check for packet length 2022-03-02 11:42:47 +01:00
sr9700.h
sr9800.c
sr9800.h
usbnet.c usbnet: fix error return code in usbnet_probe() 2021-11-02 19:48:18 +01:00
zaurus.c USB: zaurus: support another broken Zaurus 2022-03-02 11:42:47 +01:00