Bluetooth: fix UAF in bt_accept_dequeue()
Linux
Affected versions
| Product | Affected | Fixed in |
|---|---|---|
| Linux Linux |
|
Linux
| Product | Affected | Fixed in |
|---|---|---|
| Linux Linux |
|
≥ added1213395071470a900cc845a042fb51882a6 · < 26168db1ce5a9766cde021b18e590a101c056614| No fix yet |
| Linux Linux |
|
|
In the Linux kernel, the following vulnerability has been resolved:
Bluetooth: fix UAF in bt_accept_dequeue()
bt_accept_get() takes a temporary reference before dropping the accept queue lock. bt_accept_dequeue() currently drops that reference before bt_accept_unlink(), leaving only the queue reference.
bt_accept_unlink() drops the queue reference. The subsequent sock_hold() therefore accesses freed memory if it was the final reference, as observed by KASAN during listening L2CAP socket cleanup.
Retain the temporary queue-walk reference through unlink and hand it to the caller on success. Drop it explicitly on the closed and not-yet-connected paths.
From the CVE record · Linux
The Linux kernel’s Bluetooth bt_accept_dequeue() can access freed memory during listening L2CAP socket cleanup. The input does not establish how an attacker could trigger this, or whether network access, authentication, or user interaction is required.
Engineers running Linux kernels with the affected Bluetooth code should check their kernel versions; affected versions are not specified.