nfc: nci: free rx_data_reassembly skb on NCI device cleanup
Linux
Affected versions
| Product | Affected | Fixed in |
|---|---|---|
| Linux Linux |
|
Linux
| Product | Affected | Fixed in |
|---|---|---|
| Linux Linux |
|
≥ 6a2968aaf50c7a22fced77a5e24aa636281efca8 · < 16d3f507b0fa70453dc54550df093d6e9ac630c1| No fix yet |
| Linux Linux |
|
|
In the Linux kernel, the following vulnerability has been resolved:
nfc: nci: free rx_data_reassembly skb on NCI device cleanup
rx_data_reassembly skb is stored during NCI data exchange for processing fragmented packets. It is dropped only when the last fragment is processed or when an NTF packet with NCI_OP_RF_DEACTIVATE_NTF opcode is received. However, the NCI device may be deallocated before that which leads to skb leak.
As by design the rx_data_reassembly skb is bound to the NCI device and nothing prevents the device to be freed before the skb is processed in some way and cleaned, free it on the NCI device cleanup.
Found by Linux Verification Center (linuxtesting.org) with Syzkaller.
From the CVE record · Linux
The Linux kernel’s NFC NCI code can leak a packet buffer held for fragmented data if the NCI device is deallocated before the buffer is processed or released. The input does not establish an attacker path or specify network or local access, authentication, or user-interaction requirements.
Engineers running Linux kernels with NFC NCI support should check their kernel versions; affected versions are not specified.