CVE-2026-31787
xen/privcmd: fix double free via VMA splitting
Mitigation
- Upgrade Linux to 24daca4fc07f3ff8cd0e3f629cd982187f48436a or later.
Who should check
- Anyone running Linux >= d71f513985c22f1050295d1a7e4327cf9fb060da, < dbf862ce9f009128ab86b234d91413a3e450beb4; >= d71f513985c22f1050295d1a7e4327cf9fb060da, < 2b985d3a024b9e8c24e21671b34e855569763808; >= d71f513985c22f1050295d1a7e4327cf9fb060da, < 1576ff3869cbd3620717195f971c85b7d7fd62b5; >= d71f513985c22f1050295d1a7e4327cf9fb060da, < 402d84ad9e89bd4cbfd07ca8598532b7021daf95; >= d71f513985c22f1050295d1a7e4327cf9fb060da, < 2894a351fe2ea8684919d36df3188b9a35e3926f; >= d71f513985c22f1050295d1a7e4327cf9fb060da, < 446ee446d9ae66f36e95c3c90bbcc4e56b94cde0; >= d71f513985c22f1050295d1a7e4327cf9fb060da, < 71bf829800758a6e3889096e4754ef47ba7fc850; >= d71f513985c22f1050295d1a7e4327cf9fb060da, < 24daca4fc07f3ff8cd0e3f629cd982187f48436a
- Anyone running Linux 3.8
Vulnerability facts
- Affected
- Linux >= d71f513985c22f1050295d1a7e4327cf9fb060da, < dbf862ce9f009128ab86b234d91413a3e450beb4; >= d71f513985c22f1050295d1a7e4327cf9fb060da, < 2b985d3a024b9e8c24e21671b34e855569763808; >= d71f513985c22f1050295d1a7e4327cf9fb060da, < 1576ff3869cbd3620717195f971c85b7d7fd62b5; >= d71f513985c22f1050295d1a7e4327cf9fb060da, < 402d84ad9e89bd4cbfd07ca8598532b7021daf95; >= d71f513985c22f1050295d1a7e4327cf9fb060da, < 2894a351fe2ea8684919d36df3188b9a35e3926f; >= d71f513985c22f1050295d1a7e4327cf9fb060da, < 446ee446d9ae66f36e95c3c90bbcc4e56b94cde0; >= d71f513985c22f1050295d1a7e4327cf9fb060da, < 71bf829800758a6e3889096e4754ef47ba7fc850; >= d71f513985c22f1050295d1a7e4327cf9fb060da, < 24daca4fc07f3ff8cd0e3f629cd982187f48436a; Linux 3.8
- Fixed in
- Linux 2b985d3a024b9e8c24e21671b34e855569763808, Linux 1576ff3869cbd3620717195f971c85b7d7fd62b5, Linux 402d84ad9e89bd4cbfd07ca8598532b7021daf95, Linux 2894a351fe2ea8684919d36df3188b9a35e3926f, Linux 446ee446d9ae66f36e95c3c90bbcc4e56b94cde0, Linux 71bf829800758a6e3889096e4754ef47ba7fc850, Linux 24daca4fc07f3ff8cd0e3f629cd982187f48436a
- Exploited in the wild
- Not in CISA KEV
- Public exploit / PoC
- None known
- Remote exploitation
- Not remotely exploitable (local or adjacent access needed)
- CVSS
- 7.8 (v3.1, NVD)CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/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: Unchanged
- Confidentiality impact: High
- Integrity impact: High
- Availability impact: High
- EPSS
- 0.19% chance of exploitation in 30 days (percentile 5, 2026-11-26)
- CWE
- CWE-415
- Modified
Description
In the Linux kernel, the following vulnerability has been resolved: xen/privcmd: fix double free via VMA splitting privcmd_vm_ops defines .close (privcmd_close), but neither .may_split nor .open. When userspace does a partial munmap() on a privcmd mapping, the kernel splits the VMA via __split_vma(). Since may_split is NULL, the split is allowed. vm_area_dup() copies vm_private_data (a pages array allocated in alloc_empty_pages()) into the new VMA without any fixup, because there is no .open callback. Both VMAs now point to the same pages array. When the unmapped portion is closed, privcmd_close() calls: - xen_unmap_domain_gfn_range() - xen_free_unpopulated_pages() - kvfree(pages) The surviving VMA still holds the dangling pointer. When it is later destroyed, the same sequence runs again, which leads to a double free. Fix this issue by adding a .may_split callback denying the VMA split. This is XSA-487 / CVE-2026-31787
Affected and fixed versions
| Package / product | Affected | Fixed | Source |
|---|---|---|---|
| Linux | >= d71f513985c22f1050295d1a7e4327cf9fb060da, < dbf862ce9f009128ab86b234d91413a3e450beb4; >= d71f513985c22f1050295d1a7e4327cf9fb060da, < 2b985d3a024b9e8c24e21671b34e855569763808; >= d71f513985c22f1050295d1a7e4327cf9fb060da, < 1576ff3869cbd3620717195f971c85b7d7fd62b5; >= d71f513985c22f1050295d1a7e4327cf9fb060da, < 402d84ad9e89bd4cbfd07ca8598532b7021daf95; >= d71f513985c22f1050295d1a7e4327cf9fb060da, < 2894a351fe2ea8684919d36df3188b9a35e3926f; >= d71f513985c22f1050295d1a7e4327cf9fb060da, < 446ee446d9ae66f36e95c3c90bbcc4e56b94cde0; >= d71f513985c22f1050295d1a7e4327cf9fb060da, < 71bf829800758a6e3889096e4754ef47ba7fc850; >= d71f513985c22f1050295d1a7e4327cf9fb060da, < 24daca4fc07f3ff8cd0e3f629cd982187f48436a | — | cvelist |
| Linux | 3.8 | — | 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-2026-31787. Work read-only: do not install, upgrade, delete or change anything. Details: https://flawdb.com/CVE-2026-31787.md Affected: Linux >= d71f513985c22f1050295d1a7e4327cf9fb060da, < dbf862ce9f009128ab86b234d91413a3e450beb4; >= d71f513985c22f1050295d1a7e4327cf9fb060da, < 2b985d3a024b9e8c24e21671b34e855569763808; >= d71f513985c22f1050295d1a7e4327cf9fb060da, < 1576ff3869cbd3620717195f971c85b7d7fd62b5; >= d71f513985c22f1050295d1… Fixed in: Linux 2b985d3a024b9e8c24e21671b34e855569763808, Linux 1576ff3869cbd3620717195f971c85b7d7fd62b5, Linux 402d84ad9e89bd4cbfd07ca8598532b7021daf95, Linux 2894a351fe2ea8684919d36df3188b9a35e3926f, Linux 446ee446d9ae66f36e95c3c90bbcc4e56b94cde0, Linux 71bf829800758a6e3889096e4754ef47ba7fc850, Linux 24dac… 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/dbf862ce9f009128ab86b234d91413a3e450beb4
- https://git.kernel.org/stable/c/2b985d3a024b9e8c24e21671b34e855569763808
- https://git.kernel.org/stable/c/1576ff3869cbd3620717195f971c85b7d7fd62b5
- https://git.kernel.org/stable/c/402d84ad9e89bd4cbfd07ca8598532b7021daf95
- https://git.kernel.org/stable/c/2894a351fe2ea8684919d36df3188b9a35e3926f
- https://git.kernel.org/stable/c/446ee446d9ae66f36e95c3c90bbcc4e56b94cde0
- https://git.kernel.org/stable/c/71bf829800758a6e3889096e4754ef47ba7fc850
- https://git.kernel.org/stable/c/24daca4fc07f3ff8cd0e3f629cd982187f48436a
FAQ
Is CVE-2026-31787 being exploited?
There is no confirmed exploitation: CVE-2026-31787 is not in the CISA Known Exploited Vulnerabilities catalog. No public exploit code is known. EPSS estimates a 0.19% chance of exploitation in the next 30 days (as of 2026-11-26).
How serious is CVE-2026-31787?
High: CVSS 7.8 (v3.1, scored by NVD). Not remotely exploitable (local or adjacent access needed).
Which versions are affected by CVE-2026-31787?
Linux >= d71f513985c22f1050295d1a7e4327cf9fb060da, < dbf862ce9f009128ab86b234d91413a3e450beb4; >= d71f513985c22f1050295d1a7e4327cf9fb060da, < 2b985d3a024b9e8c24e21671b34e855569763808; >= d71f513985c22f1050295d1a7e4327cf9fb060da, < 1576ff3869cbd3620717195f971c85b7d7fd62b5; >= d71f513985c22f1050295d1a7e4327cf9fb060da, < 402d84ad9e89bd4cbfd07ca8598532b7021daf95; >= d71f513985c22f1050295d1a7e4327cf9fb060da, < 2894a351fe2ea8684919d36df3188b9a35e3926f; >= d71f513985c22f1050295d1a7e4327cf9fb060da, < 446ee446d9ae66f36e95c3c90bbcc4e56b94cde0; >= d71f513985c22f1050295d1a7e4327cf9fb060da, < 71bf829800758a6e3889096e4754ef47ba7fc850; >= d71f513985c22f1050295d1a7e4327cf9fb060da, < 24daca4fc07f3ff8cd0e3f629cd982187f48436a; Linux 3.8.
Is there a fix for CVE-2026-31787?
Yes. Fixed in Linux 2b985d3a024b9e8c24e21671b34e855569763808, Linux 1576ff3869cbd3620717195f971c85b7d7fd62b5, Linux 402d84ad9e89bd4cbfd07ca8598532b7021daf95, Linux 2894a351fe2ea8684919d36df3188b9a35e3926f, Linux 446ee446d9ae66f36e95c3c90bbcc4e56b94cde0, Linux 71bf829800758a6e3889096e4754ef47ba7fc850, Linux 24daca4fc07f3ff8cd0e3f629cd982187f48436a. Upgrade Linux to 24daca4fc07f3ff8cd0e3f629cd982187f48436a or later.
How do I check if I'm affected by CVE-2026-31787?
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.