android_kernel_motorola_sm6375/net/bluetooth
Repository files (latest commit first)
Filename Latest commit message Latest commit date
Dan Carpenter 07d00820bf Bluetooth: Fix race condition in hci_release_sock()
commit 11eb85ec42dc8c7a7ec519b90ccf2eeae9409de8 upstream.

Syzbot managed to trigger a use after free "KASAN: use-after-free Write
in hci_sock_bind".  I have reviewed the code manually and one possibly
cause I have found is that we are not holding lock_sock(sk) when we do
the hci_dev_put(hdev) in hci_sock_release().  My theory is that the bind
and the release are racing against each other which results in this use
after free.

Reported-by: [email protected]
Signed-off-by: Dan Carpenter <[email protected]>
Signed-off-by: Johan Hedberg <[email protected]>
Signed-off-by: Greg Kroah-Hartman <[email protected]>
2020-02-05 21:22:42 +00:00
..
bnep
cmtp
hidp
rfcomm
6lowpan.c
a2mp.c
a2mp.h
af_bluetooth.c
amp.c
amp.h
ecdh_helper.c
ecdh_helper.h
hci_conn.c
hci_core.c Bluetooth: Allow combination of BDADDR_PROPERTY and INVALID_BDADDR quirks 2020-02-01 09:34:50 +00:00
hci_debugfs.c
hci_debugfs.h
hci_event.c
hci_request.c
hci_request.h
hci_sock.c Bluetooth: Fix race condition in hci_release_sock() 2020-02-05 21:22:42 +00:00
hci_sysfs.c
Kconfig
l2cap_core.c
l2cap_sock.c
leds.c
leds.h
lib.c
Makefile
mgmt.c
mgmt_util.c
mgmt_util.h
sco.c
selftest.c
selftest.h
smp.c
smp.h