CVE-2026-98456: Bluetooth: mgmt: fix race in read_unconf_index_list()
In the Linux kernel, the following vulnerability has been resolved:
Bluetooth: mgmt: fix race in readunconfindexlist()
readunconfindexlist() counts unconfigured controllers before allocating its response, then checks the device flags again while filling it.
hcidevlistlock stabilizes list membership, but it does not serialize the per-device flags. During asynchronous controller setup, the worker can set HCIUNCONFIGURED and clear HCISETUP between the two passes. A controller omitted from the allocation count can then become eligible for the fill pass, causing an out-of-bounds write to rp->index[].
Allocate space for every device on hcidevlist. Since list membership cannot change while hcidevlistlock is held, the response remains large enough regardless of flag transitions. The reported count and response length still include only eligible unconfigured controllers.
Affected Software
Remediation
Recommended actions to resolve this vulnerability, in priority order.
- Compensating control
Allocate response space for every device on hci_dev_list before filling the response, rather than allocating only for controllers initially counted as unconfigured.