diff options
| author | Desmond Cheong Zhi Xi <[email protected]> | 2021-07-28 07:51:04 +0000 |
|---|---|---|
| committer | Marcel Holtmann <[email protected]> | 2021-07-29 11:37:29 +0000 |
| commit | 92fe24a7db751b80925214ede43f8d2be792ea7b (patch) | |
| tree | 6fe57117afa4272754715d04a63baf56a06f2202 /net/bluetooth/hci_request.c | |
| parent | Bluetooth: mgmt: Fix wrong opcode in the response for add_adv cmd (diff) | |
| download | kernel-92fe24a7db751b80925214ede43f8d2be792ea7b.tar.gz kernel-92fe24a7db751b80925214ede43f8d2be792ea7b.zip | |
Bluetooth: skip invalid hci_sync_conn_complete_evt
Syzbot reported a corrupted list in kobject_add_internal [1]. This
happens when multiple HCI_EV_SYNC_CONN_COMPLETE event packets with
status 0 are sent for the same HCI connection. This causes us to
register the device more than once which corrupts the kset list.
As this is forbidden behavior, we add a check for whether we're
trying to process the same HCI_EV_SYNC_CONN_COMPLETE event multiple
times for one connection. If that's the case, the event is invalid, so
we report an error that the device is misbehaving, and ignore the
packet.
Link: https://syzkaller.appspot.com/bug?extid=66264bf2fd0476be7e6c [1]
Reported-by: [email protected]
Tested-by: [email protected]
Signed-off-by: Desmond Cheong Zhi Xi <[email protected]>
Signed-off-by: Marcel Holtmann <[email protected]>
Diffstat (limited to 'net/bluetooth/hci_request.c')
0 files changed, 0 insertions, 0 deletions
