CVE-2026-99009: Bluetooth: RFCOMM: connect the session socket without rfcomm_mutex

Published Oct 23, 2026
·
Updated

In the Linux kernel, the following vulnerability has been resolved:

Bluetooth: RFCOMM: connect the session socket without rfcommmutex

An RFCOMM connect() issued while a BR/EDR link is being authenticated makes lockdep report a circular dependency, and the reported cycle is a real AB/BA between rfcommmutex and hdev->lock.

rfcommsecuritycfm() is called from the HCI event path, which already holds hdev->lock:

hcirxwork() hcieventpacket() hciccreadenckeysize() [hdev->lock] hciencryptcfm() [hcicblistlock] rfcommsecuritycfm() [rfcommmutex]

while an RFCOMM connect() from userspace takes the same two locks the other way round:

rfcommsockconnect() rfcommdlcopen() [rfcommmutex] rfcommdlcopen() rfcommsessioncreate() kernelconnect() l2capsockconnect() l2capchanconnect() [hdev->lock]

WARNING: possible circular locking dependency detected kworker/u131:1/1128 is trying to acquire lock: rfcommmutex, at: rfcommsecuritycfm+0x31/0x3e0 [rfcomm] but task is already holding lock: hcicblistlock, at: hciccreadenckeysize+0x1d2/0xcc0 Chain exists of: rfcommmutex --> &hdev->lock --> hcicblistlock

hciauthcompleteevt() and hciencryptchangeevt() reach the callback the same way.

Both orders have to be seen in the same boot, which is why a BR/EDR connection alone is not enough to show it: a session set up by the remote side is created by rfcommacceptconnection() in krfcommd, which calls kernelaccept() and never takes hdev->lock under rfcommmutex. Connecting a device that authenticates and encrypts the link and then calling connect() on an RFCOMM socket towards any address - the connect does not have to succeed, the order is recorded before the page timeout - reports it every time.

Only the session socket has to be connected with the lock held, and it does not: nothing else can see the socket before it is put on the session list. So connect it first and take rfcommmutex afterwards, which removes the rfcommmutex -> hdev->lock order for good, rather than keeping the HCI event path out of rfcommmutex.

rfcommsessioncreate() becomes rfcommsessionconnect(), which returns the connected socket without touching the session list, and rfcommdlcopen() adds the session once it holds the lock again. If another opener added a session for the same pair while this socket was connecting, that session is used and this socket is dropped. rfcommdlcopen() now takes the session it should use, and its state check runs after the lock is re-acquired, so a DLC that was opened or closed in the meantime is still handled.

Over an existing ACL link the connection can complete before the session reaches the list, and the wakeup from the socket callback is then lost, so krfcommd is woken once the session is visible.

Connecting without the lock opens a window in which the socket can be closed. The DLC is not on a session yet, so rfcommdlcclose() finds nothing to do and returns without touching it, and rfcommdlcopen() would then attach a DLC whose owner is gone. rfcommdlcclose() now marks such a DLC with RFCOMMCLOSED, and rfcommdlcopen() checks the mark once it holds rfcommmutex again and drops the socket instead of attaching the DLC. The mark is cleared when an open starts, so a DLC that is reused is not affected. This covers both callers of rfcommdlcopen(), the socket and the tty layer.

Affected Software

1 affected component
Linux Linux kernel

Event History

Oct 23, 2026
CVE Published
via MITRE·12:20 PM
Data Sourced
via MITRE·12:20 PM
Description

Contact

SecAlerts Pty Ltd.
132 Wickham Terrace
Fortitude Valley,
QLD 4006, Australia
info@secalerts.co
By using SecAlerts services, you agree to our services end-user license agreement. This website is safeguarded by reCAPTCHA and governed by the Google Privacy Policy and Terms of Service. All names, logos, and brands of products are owned by their respective owners, and any usage of these names, logos, and brands for identification purposes only does not imply endorsement. If you possess any content that requires removal, please get in touch with us.
© 2026 SecAlerts Pty Ltd.
ABN: 70 645 966 203, ACN: 645 966 203