CVE-2026-80787
Severity CVSS v4.0:
Pending analysis
Type:
Unavailable / Other
Publication date:
04/09/2026
Last modified:
19/10/2026
Description
In the Linux kernel, the following vulnerability has been resolved:<br />
<br />
nvmet: pci-epf: fix use-after-free in nvmet_pci_epf_exec_iod_work()<br />
<br />
nvmet_pci_epf_exec_iod_work() submits an I/O command with req->execute()<br />
and then waits for the command to complete and transfers the data back<br />
to the host. This wait is not needed for commands that do not transfer<br />
data from the device to the host. To decide whether that wait is needed,<br />
it reads iod->data_len and iod->dma_dir after calling req->execute().<br />
<br />
However, once req->execute() is called, the command may complete<br />
asynchronously on another CPU. For commands that do not require a<br />
device-to-host data transfer, nvmet_pci_epf_queue_response() calls<br />
nvmet_pci_epf_complete_iod() directly, which can free the iod before it<br />
reads iod->data_len and iod->dma_dir, resulting in the KFENCE use-after-<br />
free:<br />
<br />
BUG: KFENCE: use-after-free read in nvmet_pci_epf_exec_iod_work+0x288/0x798 [nvmet_pci_epf]<br />
<br />
Use-after-free read at 0x00000000fdfa6d03 (in kfence-#63):<br />
nvmet_pci_epf_exec_iod_work+0x288/0x798 [nvmet_pci_epf]<br />
process_one_work+0x15c/0x4f0<br />
worker_thread+0x18c/0x30c<br />
kthread+0x130/0x140<br />
ret_from_fork+0x10/0x20<br />
<br />
kfence-#63: 0x00000000e3de0e71-0x00000000c938ad62, size=712, cache=kmalloc-1k<br />
<br />
allocated by task 10 on cpu 0 at 73.995480s (0.005122s ago):<br />
mempool_kmalloc+0x1c/0x28<br />
mempool_alloc_noprof+0x40/0x9c<br />
nvmet_pci_epf_poll_sqs_work+0xd4/0x344 [nvmet_pci_epf]<br />
process_one_work+0x15c/0x4f0<br />
worker_thread+0x18c/0x30c<br />
kthread+0x130/0x140<br />
ret_from_fork+0x10/0x20<br />
<br />
freed by task 131 on cpu 3 at 73.995521s (0.008385s ago):<br />
mempool_kfree+0x10/0x20<br />
mempool_free+0x44/0x64<br />
nvmet_pci_epf_free_iod+0x88/0x98 [nvmet_pci_epf]<br />
nvmet_pci_epf_cq_work+0xfc/0x280 [nvmet_pci_epf]<br />
process_one_work+0x15c/0x4f0<br />
worker_thread+0x18c/0x30c<br />
kthread+0x130/0x140<br />
ret_from_fork+0x10/0x20<br />
<br />
Fix this by referring to iod->data_len and iod->dma_dir before calling<br />
req->execute(). The remaining iod accesses such as iod->status are only<br />
reached on the device-to-host read path. In this case,<br />
nvmet_pci_epf_queue_response() signals iod->done instead of freeing the<br />
iod, so the iod stays valid.


