In the Linux kernel, the following vulnerability has been resolved:
Bluetooth: SCO: hold sk properly in sco_conn_ready
sk deref in sco_conn_ready must be done either under conn->lock, or
holding a refcount, to avoid concurrent close. conn->sk and parent sk is
currently accessed without either, and without checking parent->sk_state:
<pre>
[Task 1] [Task 2]
sco_sock_release
sco_conn_ready
sk = conn->sk
lock_sock(sk)
conn->sk = NULL
lock_sock(sk)
release_sock(sk)
sco_sock_kill(sk)
UAF on sk deref
</pre>
and similarly for access to sco_get_sock_listen() return value.
Fix possible UAF by holding sk refcount in sco_conn_ready() and making
sco_get_sock_listen() increase refcount. Also recheck after lock_sock
that the socket is still valid. Adjust conn->sk locking so it's
protected also by lock_sock() of the associated socket if any.
CVSS Vector: CVSS:3.1/AV:A/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H
CVSS Score: 8.8
AV:A - sco_conn_ready runs from sco_connect_cfm via hci_connect_cfm on HCI Connection Complete, Synchronous Connection Complete, and deferred Connection Request for SCO/eSCO, driven by an in-range Bluetooth peer. Kernel CNA guidance classifies Bluetooth as Adjacent.
AC:L - This is a use-after-free race between sco_conn_ready and sco_sock_release/sco_sock_kill. An attacker who times HCI SCO completion against socket close (rapid peer establish/teardown or concurrent connect/close) controls both sides and can retry until the window is hit; CONFIG_BT_BREDR defaults to y.
PR:N - Incoming SCO is accepted when any listen socket exists (typical HFP/audio daemons on phones) with no Linux credentials required of the peer. sco_sock_create has no capability check, and listener close can occur from automatic bluetoothd/PipeWire teardown during connection setup.
UI:N - No victim action is required at exploit time. OS Bluetooth audio stacks keep SCO listeners and manage sockets during normal headset, hands-free, and automotive operation while peer-initiated SCO/eSCO traffic is processed.
S:U - The use-after-free corrupts in-kernel Bluetooth socket memory and can enable privilege escalation within the same host kernel security authority. It does not cross a VM, container, or IOMMU boundary.
C:H - Use-after-free of struct sock after sco_sock_kill lets an attacker reclaim the freed slab object and read kernel memory through subsequent sock operations, which per CNA guidance is High confidentiality impact.
I:H - sco_conn_ready writes sk->sk_state and makes an indirect call through sk->sk_state_change on the freed sock, a standard kernel heap UAF primitive for arbitrary write and control-flow hijack, scored High per UAF guidance.
A:H - lock_sock and subsequent sk field access on a freed socket cause a kernel oops or panic. Per CNA guidance any use-after-free is High availability impact even before full exploitation.
| Attack Vector |
Adjacent Network |
Scope |
Unchanged |
| Attack Complexity |
Low |
Confidentiality Impact |
High |
| Privileges Required |
None |
Integrity Impact |
High |
| User Interaction |
None |
Availability Impact |
High |
AV:A - sco_conn_ready runs from sco_connect_cfm via hci_connect_cfm on HCI Connection Complete, Synchronous Connection Complete, and deferred Connection Request for SCO/eSCO, driven by an in-range Bluetooth peer. Kernel CNA guidance classifies Bluetooth as Adjacent.
AC:L - This is a use-after-free race between sco_conn_ready and sco_sock_release/sco_sock_kill. An attacker who times HCI SCO completion against socket close (rapid peer establish/teardown or concurrent connect/close) controls both sides and can retry until the window is hit; CONFIG_BT_BREDR defaults to y.
PR:N - Incoming SCO is accepted when any listen socket exists (typical HFP/audio daemons on phones) with no Linux credentials required of the peer. sco_sock_create has no capability check, and listener close can occur from automatic bluetoothd/PipeWire teardown during connection setup.
UI:N - No victim action is required at exploit time. OS Bluetooth audio stacks keep SCO listeners and manage sockets during normal headset, hands-free, and automotive operation while peer-initiated SCO/eSCO traffic is processed.
S:U - The use-after-free corrupts in-kernel Bluetooth socket memory and can enable privilege escalation within the same host kernel security authority. It does not cross a VM, container, or IOMMU boundary.
C:H - Use-after-free of struct sock after sco_sock_kill lets an attacker reclaim the freed slab object and read kernel memory through subsequent sock operations, which per CNA guidance is High confidentiality impact.
I:H - sco_conn_ready writes sk->sk_state and makes an indirect call through sk->sk_state_change on the freed sock, a standard kernel heap UAF primitive for arbitrary write and control-flow hijack, scored High per UAF guidance.
A:H - lock_sock and subsequent sk field access on a freed socket cause a kernel oops or panic. Per CNA guidance any use-after-free is High availability impact even before full exploitation.
CVSS 3.1