{"api_version":"1","generated_at":"2026-12-03T13:22:22+00:00","cve":"CVE-2026-143400","urls":{"html":"https://cve.report/CVE-2026-143400","api":"https://cve.report/api/cve/CVE-2026-143400.json","docs":"https://cve.report/api","cve_org":"https://www.cve.org/CVERecord?id=CVE-2026-143400","nvd":"https://nvd.nist.gov/vuln/detail/CVE-2026-143400"},"summary":{"title":"virtio_net: check RX buffer length before DMA sync","description":"In the Linux kernel, the following vulnerability has been resolved:\n\nvirtio_net: check RX buffer length before DMA sync\n\nAn RX queue that uses the DMA API (rq->use_page_pool_dma, for example\nwith VIRTIO_F_ACCESS_PLATFORM) syncs each received buffer with\npage_pool_dma_sync_for_cpu() using the length the device wrote to the\nused ring, and checks that length against the posted buffer only after\nthe sync.\n\nWith SWIOTLB bouncing (swiotlb=force, or a confidential-computing\nguest), the sync copies from the shared bounce buffer into the guest's\nprivate page, so an oversized length also copies the bytes the device\nwrote past the posted buffer over the neighbouring page pool fragments.\nThe later check drops the packet, but the copy has already happened. A\nmalicious device, such as a host the confidential guest does not\ntrust, can overwrite guest kernel memory next to an RX buffer with\nbytes it chooses, which is enough to take an unprivileged guest\nprocess to root.\n\nCheck the length before the sync in the per-fragment loops.\nreceive_buf() has to sync the header before the length check, because\nthe mergeable error path reads num_buffers from it, so limit that sync\nto the posted length. A device that reports correct lengths sees no\nchange.\n\nThe driver has synced with the device's length since\ncommit 295525e29a5b (\"virtio_net: merge dma operations when filling\nmergeable buffers\"), at first in virtnet_rq_unmap(). Commit 24fbd3967f3f\n(\"virtio_net: add page_pool support for buffer allocation\") moved the\nsync to the page_pool call sites that this patch changes, so the patch\napplies to v7.1 and later. Older kernels need a separate backport that\nlimits the sync in virtnet_rq_unmap().\n\nFound by an LLM code review agent auditing users of the DMA API; the\nfix and this changelog were also written with an LLM coding assistant\nand reviewed by us. Reproduced in QEMU with swiotlb=force and\niommu_platform=on, a test-only device change that reports a used length\n64 bytes past the posted buffer and writes a marker there, and a guest\nkprobe module that reads the buffer after the sync: without this patch\nthe marker reaches the guest page for small and mergeable buffers; with\nit the packets are dropped and counted in rx_length_errors. The\nvirtio_net selftest basic_features.sh passes with and without mergeable\nbuffers.","state":"PUBLISHED","assigner":"Linux","published_at":"2026-12-03 10:18:33","updated_at":"2026-12-03 10:18:33"},"problem_types":[],"metrics":[],"references":[{"url":"https://git.kernel.org/stable/c/a1d50a6bff4a593977478202119f2f544e8e2eae","name":"https://git.kernel.org/stable/c/a1d50a6bff4a593977478202119f2f544e8e2eae","refsource":"416baaa9-dc9f-4396-8d5f-8c081fb06d67","tags":[],"title":"","mime":"","httpstatus":"","archivestatus":"0"},{"url":"https://git.kernel.org/stable/c/fae39d56c607075624a1be08c94cdac059f79889","name":"https://git.kernel.org/stable/c/fae39d56c607075624a1be08c94cdac059f79889","refsource":"416baaa9-dc9f-4396-8d5f-8c081fb06d67","tags":[],"title":"","mime":"","httpstatus":"","archivestatus":"0"},{"url":"https://git.kernel.org/stable/c/29dfa436bc488056a84ee423ba82336db453e2a6","name":"https://git.kernel.org/stable/c/29dfa436bc488056a84ee423ba82336db453e2a6","refsource":"416baaa9-dc9f-4396-8d5f-8c081fb06d67","tags":[],"title":"","mime":"","httpstatus":"","archivestatus":"0"},{"url":"https://www.cve.org/CVERecord?id=CVE-2026-143400","name":"CVE Program record","refsource":"CVE.ORG","tags":["canonical"]},{"url":"https://nvd.nist.gov/vuln/detail/CVE-2026-143400","name":"NVD vulnerability detail","refsource":"NVD","tags":["canonical","analysis"]}],"affected":[{"source":"CNA","vendor":"Linux","product":"Linux","version":"affected 295525e29a5b5694a6e96864f0c1365f79639863 fae39d56c607075624a1be08c94cdac059f79889 git","platforms":[]},{"source":"CNA","vendor":"Linux","product":"Linux","version":"affected 295525e29a5b5694a6e96864f0c1365f79639863 a1d50a6bff4a593977478202119f2f544e8e2eae git","platforms":[]},{"source":"CNA","vendor":"Linux","product":"Linux","version":"affected 295525e29a5b5694a6e96864f0c1365f79639863 29dfa436bc488056a84ee423ba82336db453e2a6 git","platforms":[]},{"source":"CNA","vendor":"Linux","product":"Linux","version":"affected 6.6","platforms":[]},{"source":"CNA","vendor":"Linux","product":"Linux","version":"unaffected 6.6 semver","platforms":[]},{"source":"CNA","vendor":"Linux","product":"Linux","version":"unaffected 6.18.66 6.18.* semver","platforms":[]},{"source":"CNA","vendor":"Linux","product":"Linux","version":"unaffected 7.3.7 7.3.* semver","platforms":[]},{"source":"CNA","vendor":"Linux","product":"Linux","version":"unaffected 7.4-rc4 * original_commit_for_fix","platforms":[]}],"timeline":[],"solutions":[],"workarounds":[],"exploits":[],"credits":[],"nvd_cpes":[],"vendor_comments":[],"enrichments":{"kev":null,"epss":null,"legacy_qids":[]},"source_records":{"cve_program":{"containers":{"cna":{"affected":[{"defaultStatus":"unaffected","product":"Linux","programFiles":["drivers/net/virtio_net.c"],"repo":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","vendor":"Linux","versions":[{"lessThan":"fae39d56c607075624a1be08c94cdac059f79889","status":"affected","version":"295525e29a5b5694a6e96864f0c1365f79639863","versionType":"git"},{"lessThan":"a1d50a6bff4a593977478202119f2f544e8e2eae","status":"affected","version":"295525e29a5b5694a6e96864f0c1365f79639863","versionType":"git"},{"lessThan":"29dfa436bc488056a84ee423ba82336db453e2a6","status":"affected","version":"295525e29a5b5694a6e96864f0c1365f79639863","versionType":"git"}]},{"defaultStatus":"affected","product":"Linux","programFiles":["drivers/net/virtio_net.c"],"repo":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","vendor":"Linux","versions":[{"status":"affected","version":"6.6"},{"lessThan":"6.6","status":"unaffected","version":"0","versionType":"semver"},{"lessThanOrEqual":"6.18.*","status":"unaffected","version":"6.18.66","versionType":"semver"},{"lessThanOrEqual":"7.3.*","status":"unaffected","version":"7.3.7","versionType":"semver"},{"lessThanOrEqual":"*","status":"unaffected","version":"7.4-rc4","versionType":"original_commit_for_fix"}]}],"cpeApplicability":[{"nodes":[{"cpeMatch":[{"criteria":"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*","versionEndExcluding":"6.18.66","versionStartIncluding":"6.6","vulnerable":true},{"criteria":"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*","versionEndExcluding":"7.3.7","versionStartIncluding":"6.6","vulnerable":true},{"criteria":"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*","versionEndExcluding":"7.4-rc4","versionStartIncluding":"6.6","vulnerable":true}],"negate":false,"operator":"OR"}]}],"descriptions":[{"lang":"en","value":"In the Linux kernel, the following vulnerability has been resolved:\n\nvirtio_net: check RX buffer length before DMA sync\n\nAn RX queue that uses the DMA API (rq->use_page_pool_dma, for example\nwith VIRTIO_F_ACCESS_PLATFORM) syncs each received buffer with\npage_pool_dma_sync_for_cpu() using the length the device wrote to the\nused ring, and checks that length against the posted buffer only after\nthe sync.\n\nWith SWIOTLB bouncing (swiotlb=force, or a confidential-computing\nguest), the sync copies from the shared bounce buffer into the guest's\nprivate page, so an oversized length also copies the bytes the device\nwrote past the posted buffer over the neighbouring page pool fragments.\nThe later check drops the packet, but the copy has already happened. A\nmalicious device, such as a host the confidential guest does not\ntrust, can overwrite guest kernel memory next to an RX buffer with\nbytes it chooses, which is enough to take an unprivileged guest\nprocess to root.\n\nCheck the length before the sync in the per-fragment loops.\nreceive_buf() has to sync the header before the length check, because\nthe mergeable error path reads num_buffers from it, so limit that sync\nto the posted length. A device that reports correct lengths sees no\nchange.\n\nThe driver has synced with the device's length since\ncommit 295525e29a5b (\"virtio_net: merge dma operations when filling\nmergeable buffers\"), at first in virtnet_rq_unmap(). Commit 24fbd3967f3f\n(\"virtio_net: add page_pool support for buffer allocation\") moved the\nsync to the page_pool call sites that this patch changes, so the patch\napplies to v7.1 and later. Older kernels need a separate backport that\nlimits the sync in virtnet_rq_unmap().\n\nFound by an LLM code review agent auditing users of the DMA API; the\nfix and this changelog were also written with an LLM coding assistant\nand reviewed by us. Reproduced in QEMU with swiotlb=force and\niommu_platform=on, a test-only device change that reports a used length\n64 bytes past the posted buffer and writes a marker there, and a guest\nkprobe module that reads the buffer after the sync: without this patch\nthe marker reaches the guest page for small and mergeable buffers; with\nit the packets are dropped and counted in rx_length_errors. The\nvirtio_net selftest basic_features.sh passes with and without mergeable\nbuffers."}],"providerMetadata":{"dateUpdated":"2026-12-03T09:22:40.108Z","orgId":"416baaa9-dc9f-4396-8d5f-8c081fb06d67","shortName":"Linux"},"references":[{"url":"https://git.kernel.org/stable/c/fae39d56c607075624a1be08c94cdac059f79889"},{"url":"https://git.kernel.org/stable/c/a1d50a6bff4a593977478202119f2f544e8e2eae"},{"url":"https://git.kernel.org/stable/c/29dfa436bc488056a84ee423ba82336db453e2a6"}],"title":"virtio_net: check RX buffer length before DMA sync","x_generator":{"engine":"bippy-1.2.0"}}},"cveMetadata":{"assignerOrgId":"416baaa9-dc9f-4396-8d5f-8c081fb06d67","assignerShortName":"Linux","cveId":"CVE-2026-143400","datePublished":"2026-12-03T09:22:40.108Z","dateReserved":"2026-12-03T03:10:28.373Z","dateUpdated":"2026-12-03T09:22:40.108Z","state":"PUBLISHED"},"dataType":"CVE_RECORD","dataVersion":"5.2"},"nvd":{"publishedDate":"2026-12-03 10:18:33","lastModifiedDate":"2026-12-03 10:18:33","problem_types":[],"metrics":[],"configurations":[]},"legacy_mitre":{"record":{"CveYear":"2026","CveId":"143400","Ordinal":"1","Title":"virtio_net: check RX buffer length before DMA sync","CVE":"CVE-2026-143400","Year":"2026"},"notes":[{"CveYear":"2026","CveId":"143400","Ordinal":"1","NoteData":"In the Linux kernel, the following vulnerability has been resolved:\n\nvirtio_net: check RX buffer length before DMA sync\n\nAn RX queue that uses the DMA API (rq->use_page_pool_dma, for example\nwith VIRTIO_F_ACCESS_PLATFORM) syncs each received buffer with\npage_pool_dma_sync_for_cpu() using the length the device wrote to the\nused ring, and checks that length against the posted buffer only after\nthe sync.\n\nWith SWIOTLB bouncing (swiotlb=force, or a confidential-computing\nguest), the sync copies from the shared bounce buffer into the guest's\nprivate page, so an oversized length also copies the bytes the device\nwrote past the posted buffer over the neighbouring page pool fragments.\nThe later check drops the packet, but the copy has already happened. A\nmalicious device, such as a host the confidential guest does not\ntrust, can overwrite guest kernel memory next to an RX buffer with\nbytes it chooses, which is enough to take an unprivileged guest\nprocess to root.\n\nCheck the length before the sync in the per-fragment loops.\nreceive_buf() has to sync the header before the length check, because\nthe mergeable error path reads num_buffers from it, so limit that sync\nto the posted length. A device that reports correct lengths sees no\nchange.\n\nThe driver has synced with the device's length since\ncommit 295525e29a5b (\"virtio_net: merge dma operations when filling\nmergeable buffers\"), at first in virtnet_rq_unmap(). Commit 24fbd3967f3f\n(\"virtio_net: add page_pool support for buffer allocation\") moved the\nsync to the page_pool call sites that this patch changes, so the patch\napplies to v7.1 and later. Older kernels need a separate backport that\nlimits the sync in virtnet_rq_unmap().\n\nFound by an LLM code review agent auditing users of the DMA API; the\nfix and this changelog were also written with an LLM coding assistant\nand reviewed by us. Reproduced in QEMU with swiotlb=force and\niommu_platform=on, a test-only device change that reports a used length\n64 bytes past the posted buffer and writes a marker there, and a guest\nkprobe module that reads the buffer after the sync: without this patch\nthe marker reaches the guest page for small and mergeable buffers; with\nit the packets are dropped and counted in rx_length_errors. The\nvirtio_net selftest basic_features.sh passes with and without mergeable\nbuffers.","Type":"Description","Title":"virtio_net: check RX buffer length before DMA sync"}]}}}