Zheyu Ma
1248582e47
can: peak_pci: peak_pci_remove(): fix UAF
commit 949fe9b35570361bc6ee2652f89a0561b26eec98 upstream.
When remove the module peek_pci, referencing 'chan' again after
releasing 'dev' will cause UAF.
Fix this by releasing 'dev' later.
The following log reveals it:
[ 35.961814 ] BUG: KASAN: use-after-free in peak_pci_remove+0x16f/0x270 [peak_pci]
[ 35.963414 ] Read of size 8 at addr ffff888136998ee8 by task modprobe/5537
[ 35.965513 ] Call Trace:
[ 35.965718 ] dump_stack_lvl+0xa8/0xd1
[ 35.966028 ] print_address_description+0x87/0x3b0
[ 35.966420 ] kasan_report+0x172/0x1c0
[ 35.966725 ] ? peak_pci_remove+0x16f/0x270 [peak_pci]
[ 35.967137 ] ? trace_irq_enable_rcuidle+0x10/0x170
[ 35.967529 ] ? peak_pci_remove+0x16f/0x270 [peak_pci]
[ 35.967945 ] __asan_report_load8_noabort+0x14/0x20
[ 35.968346 ] peak_pci_remove+0x16f/0x270 [peak_pci]
[ 35.968752 ] pci_device_remove+0xa9/0x250
Fixes: e6d9c80b7c ("can: peak_pci: add support of some new PEAK-System PCI cards")
Link: https://lore.kernel.org/all/[email protected]
Cc: [email protected]
Signed-off-by: Zheyu Ma <[email protected]>
Signed-off-by: Marc Kleine-Budde <[email protected]>
Signed-off-by: Greg Kroah-Hartman <[email protected]>
|
2021-10-27 09:54:26 +02:00 |
| .. |
|
appletalk
|
net: appletalk: cops: Fix data race in cops_probe1
|
2021-06-16 11:59:36 +02:00 |
|
arcnet
|
|
|
|
bonding
|
bonding: 3ad: fix the concurrency between __bond_release_one() and bond_3ad_state_machine_handler()
|
2021-09-22 12:26:30 +02:00 |
|
caif
|
net: caif: fix memory leak in ldisc_open
|
2021-06-30 08:47:47 -04:00 |
|
can
|
can: peak_pci: peak_pci_remove(): fix UAF
|
2021-10-27 09:54:26 +02:00 |
|
dsa
|
net: dsa: lantiq_gswip: fix register definition
|
2021-10-27 09:54:25 +02:00 |
|
ethernet
|
net: enetc: fix ethtool counter name for PM0_TERR
|
2021-10-27 09:54:26 +02:00 |
|
fddi
|
net: fddi: fix UAF in fza_probe
|
2021-07-25 14:35:15 +02:00 |
|
fjes
|
fjes: check return value after calling platform_get_resource()
|
2021-07-19 08:53:10 +02:00 |
|
hamradio
|
net: 6pack: Fix tx timeout and slot time
|
2021-09-30 10:09:26 +02:00 |
|
hippi
|
|
|
|
hyperv
|
|
|
|
ieee802154
|
ieee802154: hwsim: fix GPF in hwsim_new_edge_nl
|
2021-08-18 08:56:57 +02:00 |
|
ipvlan
|
|
|
|
netdevsim
|
|
|
|
phy
|
net: phy: bcm7xxx: Fixed indirect MMD operations
|
2021-10-17 10:42:33 +02:00 |
|
plip
|
|
|
|
ppp
|
ppp: Fix generating ifname when empty IFLA_IFNAME is specified
|
2021-08-18 08:56:59 +02:00 |
|
slip
|
|
|
|
team
|
|
|
|
usb
|
lan78xx: select CRC32
|
2021-10-27 09:54:25 +02:00 |
|
vmxnet3
|
|
|
|
wan
|
|
|
|
wimax
|
|
|
|
wireless
|
mac80211-hwsim: fix late beacon hrtimer handling
|
2021-10-06 15:42:32 +02:00 |
|
xen-netback
|
xen-netback: correct success/error reporting for the SKB-with-fraglist case
|
2021-10-09 14:39:49 +02:00 |
|
dummy.c
|
|
|
|
eql.c
|
|
|
|
geneve.c
|
net: geneve: modify IP header check in geneve6_xmit_skb and geneve_xmit_skb
|
2021-05-14 09:44:31 +02:00 |
|
gtp.c
|
|
|
|
ifb.c
|
|
|
|
Kconfig
|
|
|
|
LICENSE.SRC
|
|
|
|
loopback.c
|
|
|
|
macsec.c
|
|
|
|
macvlan.c
|
|
|
|
macvtap.c
|
|
|
|
Makefile
|
|
|
|
mdio.c
|
|
|
|
mii.c
|
|
|
|
net_failover.c
|
|
|
|
netconsole.c
|
|
|
|
nlmon.c
|
|
|
|
ntb_netdev.c
|
|
|
|
rionet.c
|
|
|
|
sb1000.c
|
|
|
|
Space.c
|
|
|
|
sungem_phy.c
|
|
|
|
tap.c
|
|
|
|
thunderbolt.c
|
|
|
|
tun.c
|
|
|
|
veth.c
|
|
|
|
virtio_net.c
|
virtio-net: use NETIF_F_GRO_HW instead of NETIF_F_LRO
|
2021-08-26 08:36:18 -04:00 |
|
vrf.c
|
vrf: Reset skb conntrack connection on VRF rcv
|
2021-08-26 08:36:18 -04:00 |
|
vsockmon.c
|
|
|
|
vxlan.c
|
vxlan: add missing rcu_read_lock() in neigh_reduce()
|
2021-07-14 16:53:31 +02:00 |
|
xen-netfront.c
|
|
|