CVE-2024-35804
KVM: x86: Mark target gfn of emulated atomic instruction as dirty
Mitigation
- Upgrade Linux to 5.19 or later.
Who should check
- Anyone running Linux >= d97c0667c1e61ded6639117b4b9584a9c12b7e66, < a9bd6bb6f02bf7132c1ab192ba62bbfa52df7d66; >= 1c2361f667f3648855ceae25f1332c18413fdb9f, < 726374dde5d608b15b9756bd52b6fc283fda7a06; >= 1c2361f667f3648855ceae25f1332c18413fdb9f, < 9d1b22e573a3789ed1f32033ee709106993ba551; >= 1c2361f667f3648855ceae25f1332c18413fdb9f, < 225d587a073584946c05c9b7651d637bd45c0c71; >= 1c2361f667f3648855ceae25f1332c18413fdb9f, < 910c57dfa4d113aae6571c2a8b9ae8c430975902; b0f294103f4cf733e23d3f0c4e5fd58e42998921; e964665cc7ca13a16992b205fce63554b9efc78b; >= 5.15.58, < 5.15.154; >= 5.17.13, < 5.18; >= 5.18.2, < 5.19
- Anyone running Linux 5.19
Vulnerability facts
- Affected
- Linux >= d97c0667c1e61ded6639117b4b9584a9c12b7e66, < a9bd6bb6f02bf7132c1ab192ba62bbfa52df7d66; >= 1c2361f667f3648855ceae25f1332c18413fdb9f, < 726374dde5d608b15b9756bd52b6fc283fda7a06; >= 1c2361f667f3648855ceae25f1332c18413fdb9f, < 9d1b22e573a3789ed1f32033ee709106993ba551; >= 1c2361f667f3648855ceae25f1332c18413fdb9f, < 225d587a073584946c05c9b7651d637bd45c0c71; >= 1c2361f667f3648855ceae25f1332c18413fdb9f, < 910c57dfa4d113aae6571c2a8b9ae8c430975902; b0f294103f4cf733e23d3f0c4e5fd58e42998921; e964665cc7ca13a16992b205fce63554b9efc78b; >= 5.15.58, < 5.15.154; >= 5.17.13, < 5.18; >= 5.18.2, < 5.19; Linux 5.19
- Fixed in
- Linux 726374dde5d608b15b9756bd52b6fc283fda7a06, Linux 9d1b22e573a3789ed1f32033ee709106993ba551, Linux 225d587a073584946c05c9b7651d637bd45c0c71, Linux 910c57dfa4d113aae6571c2a8b9ae8c430975902, Linux 5.15.154, Linux 5.18, Linux 5.19
- Exploited in the wild
- Not in CISA KEV
- Public exploit / PoC
- None known
- Remote exploitation
- Not remotely exploitable (local or adjacent access needed)
- CVSS
- 8.8 (v3.1, CNA)CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:C/C:H/I:H/A:HOpen in CVSS calculator
Show all 8 CVSS metrics
- Attack vector: Local
- Attack complexity: Low
- Privileges required: Low
- User interaction: None
- Scope: Changed (impact reaches other components)
- Confidentiality impact: High
- Integrity impact: High
- Availability impact: High
- EPSS
- 0.33% chance of exploitation in 30 days (percentile 18, 2026-11-26)
- CWE
- CWE-401
- Modified
Description
In the Linux kernel, the following vulnerability has been resolved: KVM: x86: Mark target gfn of emulated atomic instruction as dirty When emulating an atomic access on behalf of the guest, mark the target gfn dirty if the CMPXCHG by KVM is attempted and doesn't fault. This fixes a bug where KVM effectively corrupts guest memory during live migration by writing to guest memory without informing userspace that the page is dirty. Marking the page dirty got unintentionally dropped when KVM's emulated CMPXCHG was converted to do a user access. Before that, KVM explicitly mapped the guest page into kernel memory, and marked the page dirty during the unmap phase. Mark the page dirty even if the CMPXCHG fails, as the old data is written back on failure, i.e. the page is still written. The value written is guaranteed to be the same because the operation is atomic, but KVM's ABI is that all writes are dirty logged regardless of the value written. And more importantly, that's what KVM did before the buggy commit. Huge kudos to the folks on the Cc list (and many others), who did all the actual work of triaging and debugging. base-commit: 6769ea8da8a93ed4630f1ce64df6aafcaabfce64
Affected and fixed versions
| Package / product | Affected | Fixed | Source |
|---|---|---|---|
| Linux | >= d97c0667c1e61ded6639117b4b9584a9c12b7e66, < a9bd6bb6f02bf7132c1ab192ba62bbfa52df7d66; >= 1c2361f667f3648855ceae25f1332c18413fdb9f, < 726374dde5d608b15b9756bd52b6fc283fda7a06; >= 1c2361f667f3648855ceae25f1332c18413fdb9f, < 9d1b22e573a3789ed1f32033ee709106993ba551; >= 1c2361f667f3648855ceae25f1332c18413fdb9f, < 225d587a073584946c05c9b7651d637bd45c0c71; >= 1c2361f667f3648855ceae25f1332c18413fdb9f, < 910c57dfa4d113aae6571c2a8b9ae8c430975902; b0f294103f4cf733e23d3f0c4e5fd58e42998921; e964665cc7ca13a16992b205fce63554b9efc78b; >= 5.15.58, < 5.15.154; >= 5.17.13, < 5.18; >= 5.18.2, < 5.19 | — | cvelist |
| Linux | 5.19 | — | cvelist |
Check your systems with an agent
Paste this into Claude Code, Cursor or another coding agent. It only reads; it changes nothing.
Check whether anything I run is affected by CVE-2024-35804. Work read-only: do not install, upgrade, delete or change anything. Details: https://flawdb.com/CVE-2024-35804.md Affected: Linux >= d97c0667c1e61ded6639117b4b9584a9c12b7e66, < a9bd6bb6f02bf7132c1ab192ba62bbfa52df7d66; >= 1c2361f667f3648855ceae25f1332c18413fdb9f, < 726374dde5d608b15b9756bd52b6fc283fda7a06; >= 1c2361f667f3648855ceae25f1332c18413fdb9f, < 9d1b22e573a3789ed1f32033ee709106993ba551; >= 1c2361f667f3648855ceae2… Fixed in: Linux 726374dde5d608b15b9756bd52b6fc283fda7a06, Linux 9d1b22e573a3789ed1f32033ee709106993ba551, Linux 225d587a073584946c05c9b7651d637bd45c0c71, Linux 910c57dfa4d113aae6571c2a8b9ae8c430975902, Linux 5.15.154, Linux 5.18, Linux 5.19 Steps: 1. Search this machine and project for Linux: dependency manifests and lockfiles, installed packages, container images and running services. 2. For each match, note the installed version and whether it is inside the affected range. 3. Report a table: location, installed version, affected (yes / no / unsure), evidence. If affected, say which fixed version or mitigation from the details link applies, but don't apply it.
References
Patches
- https://git.kernel.org/stable/c/a9bd6bb6f02bf7132c1ab192ba62bbfa52df7d66
- https://git.kernel.org/stable/c/726374dde5d608b15b9756bd52b6fc283fda7a06
- https://git.kernel.org/stable/c/9d1b22e573a3789ed1f32033ee709106993ba551
- https://git.kernel.org/stable/c/225d587a073584946c05c9b7651d637bd45c0c71
- https://git.kernel.org/stable/c/910c57dfa4d113aae6571c2a8b9ae8c430975902
FAQ
Is CVE-2024-35804 being exploited?
There is no confirmed exploitation: CVE-2024-35804 is not in the CISA Known Exploited Vulnerabilities catalog. No public exploit code is known. EPSS estimates a 0.33% chance of exploitation in the next 30 days (as of 2026-11-26).
How serious is CVE-2024-35804?
High: CVSS 8.8 (v3.1, scored by CNA). Not remotely exploitable (local or adjacent access needed).
Which versions are affected by CVE-2024-35804?
Linux >= d97c0667c1e61ded6639117b4b9584a9c12b7e66, < a9bd6bb6f02bf7132c1ab192ba62bbfa52df7d66; >= 1c2361f667f3648855ceae25f1332c18413fdb9f, < 726374dde5d608b15b9756bd52b6fc283fda7a06; >= 1c2361f667f3648855ceae25f1332c18413fdb9f, < 9d1b22e573a3789ed1f32033ee709106993ba551; >= 1c2361f667f3648855ceae25f1332c18413fdb9f, < 225d587a073584946c05c9b7651d637bd45c0c71; >= 1c2361f667f3648855ceae25f1332c18413fdb9f, < 910c57dfa4d113aae6571c2a8b9ae8c430975902; b0f294103f4cf733e23d3f0c4e5fd58e42998921; e964665cc7ca13a16992b205fce63554b9efc78b; >= 5.15.58, < 5.15.154; >= 5.17.13, < 5.18; >= 5.18.2, < 5.19; Linux 5.19.
Is there a fix for CVE-2024-35804?
Yes. Fixed in Linux 726374dde5d608b15b9756bd52b6fc283fda7a06, Linux 9d1b22e573a3789ed1f32033ee709106993ba551, Linux 225d587a073584946c05c9b7651d637bd45c0c71, Linux 910c57dfa4d113aae6571c2a8b9ae8c430975902, Linux 5.15.154, Linux 5.18, Linux 5.19. Upgrade Linux to 5.19 or later.
How do I check if I'm affected by CVE-2024-35804?
Find where you use the affected software (dependency lockfiles, installed packages, container images, servers) and compare the installed version with the affected range above. The agent prompt on this page does this read-only.