KernelScan.io

HIGH

nci DataExchange Race

CVE-2026-90224

CVSS 7.5 / 10.0 NVD

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

KernelScan AI7.1HIGH

01

In the Linux kernel, the following vulnerability has been resolved: nfc: nci: fix double completion race in nci_data_exchange_complete nci_close_device() and nci_rx_work can both call nci_data_exchange_complete() concurrently. After commit 4527025d440ce8 ("nfc: nci: fix circular locking dependency in nci_close_device") moved flush_workqueue(ndev->rx_wq) after mutex_unlock(&ndev->req_lock), rx_work is no longer serialized with the explicit completion call in the close path. Both callers read the non-NULL callback pointer and invoke rawsock_data_exchange_complete(), which calls sock_put() -- but only one sock_hold() was taken, so the second sock_put() underflows the refcount and frees the socket while it is still in use. Replace the bare clear_bit(NCI_DATA_EXCHANGE) with test_and_clear_bit() so that only the first caller proceeds to invoke the callback.

02

Engine v0.6.0

Risk summary

A local attacker with access to an NFC device can trigger a race between device close and data reception that causes a socket reference count underflow, leading to a use-after-free. This can result in kernel memory corruption, privilege escalation, or a system crash. Exploitation requires NFC hardware to be present and winning a narrow race window.

Affectednet/nfc/nci/data.c (NFC NCI protocol)

Vulnerability analysis

A race condition exists in the NFC data exchange completion path: when a device is closed while incoming data is still being processed, both the close path and the incoming-data path can finish the exchange. Each path releases the socket, but only one hold was ever placed on it, so the second release frees the socket while it is still in use. The fix ensures only the first path to claim completion actually finishes the exchange; the second sees it is already done and exits early. An attacker with access to NFC hardware can reach this by starting a data exchange and closing the device at the same time data arrives.

03

BranchIntroducedFixed inPatch commit
5.155.15.2035.15.221588ccd19a6e6
6.126.12.806.12.110bfdf412208fe
6.186.18.216.18.52ba4c776af3dc
mainline—7.3-rc1—
5.105.10.2535.10.2703f0758327340
6.66.6.1316.6.1579030a1bbe2c6
6.16.1.1686.1.188cf646a9f5554
7.2—7.2.68265a626cc14
6.196.19.116.20ee08414d78b8
cip/6.12—6.12.111-cip32bfdf412208fe