KernelScan.io

HIGH

bluetooth L2CAPSockOpt UAF

CVE-2026-90093

CVSS 7.8 / 10.0 NVD

CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H

KernelScan AI7.2HIGH

01

In the Linux kernel, the following vulnerability has been resolved: Bluetooth: L2CAP: access chan->conn safely in get/setsockopt Since commit b66774b48dd9 ("Bluetooth: L2CAP: Fix UAF in channel timeout by holding conn ref") l2cap_chan::conn has held reference and remains non-NULL also after the corresponding hci_conn is deleted. In this state accessing various fields eg. hci_conn::hdev is invalid, which leads to KASAN crash in l2cap_sock_setsockopt() access of conn->hcon->hdev. Check l2cap_chan::conn.hcon corresponds to an alive hci_conn before trying to use it in l2cap_sock.c. Hold l2cap_chan_lock() in getsockopt/setsockopt to ensure it stays alive, and to avoid data races in l2cap_chan fields.

02

Engine v0.6.0

Risk summary

A local user with access to Bluetooth L2CAP sockets can trigger a use-after-free by racing a getsockopt or setsockopt call against connection teardown. The freed HCI connection object is dereferenced through a stale pointer, leading to kernel memory corruption that can cause information disclosure, privilege escalation, or a kernel panic. Systems with Bluetooth enabled and local untrusted users are at risk.

Affectednet/bluetooth/l2cap_sock.c (Bluetooth L2CAP)

Vulnerability analysis

After a prior fix began holding a reference on the L2CAP connection object, the connection pointer in an L2CAP channel remained non-NULL even after the underlying HCI connection was deleted. The socket option handlers only checked whether the connection pointer was non-NULL before dereferencing it to access the HCI connection's device handle and other fields, so a getsockopt or setsockopt call that raced with connection teardown would access freed memory. The fix adds a check for a flag that the connection deletion path sets before removing the HCI connection, returning an error if the connection is being torn down, and holds the channel lock across the entire option access to prevent the race. A local user who can create and use Bluetooth L2CAP sockets can trigger this; no special privileges beyond a local account are required, though the race window is narrow.

03

BranchIntroducedFixed inPatch commit
5.105.10.2655.11f49321c85785
5.155.15.2165.16ca2c4c264986
6.16.1.1836.2—
6.126.12.976.12.1143af72bf8f73c
6.186.18.396.18.578460dc49c975
6.66.6.1456.6.16019e154d794eb
7.17.1.47.2—
7.2—7.2.6—
mainline—7.3—

04

State of the newest release of each Civil Infrastructure Platform SLTS tree, from CIP's own fix records.

CIP treeState
cip/6.12Affected — no CIP fix yet (latest 6.12.112-cip33)
cip/6.1Affected — no CIP fix yet (latest 6.1.189-cip61)
cip/6.1-rtAffected — no CIP fix yet (latest 6.1.189-cip61-rt32)
cip/5.10Affected — no CIP fix yet (latest 5.10.271-cip78)
cip/5.10-rtAffected — no CIP fix yet (latest 5.10.268-cip77-rt34)