Host kernel code execution via stale I/O bus
Published Feb 29, 2024 · Updated Aug 5, 2026
Use-after-free in KVM in Linux 5.9 through 5.12.3 allows local users to execute code in the host kernel through KVM ioctls. In virt/kvm/kvm_main.c, a failed I/O-bus reallocation destroys registered devices before SRCU readers observe the replacement null bus, leaving readers to invoke freed device operations. Exploitation requires local access to /dev/kvm, VM creation, concurrent unregister and MMIO or PIO activity, and induced allocation failure; success can crash the host or execute code in its kernel.
Summary
What happened
Use-after-free in KVM in Linux 5.9 through 5.12.3 allows local users to execute code in the host kernel through KVM ioctls. In virt/kvm/kvm_main.c, a failed I/O-bus reallocation destroys registered devices before SRCU readers observe the replacement null bus, leaving readers to invoke freed device operations. Exploitation requires local access to /dev/kvm, VM creation, concurrent unregister and MMIO or PIO activity, and induced allocation failure; success can crash the host or execute code in its kernel.
The record
- CVE
- CVE-2021-47061
- Published
- Feb 29, 2024
- Updated
- Aug 5, 2026
- Vendor
- The Linux Kernel Organization
- Product
- Linux
- Classifications
- CWE-416, T1068
- Attack vector
- local
- Privileges
- authenticated
Timeline
How it unfolded
- Feb 29, 2024CVE publishedPublication date reported by the CVE source.
- Aug 5, 2026Record updatedLatest update available in the CVE record.
Exploitability
Present is not the same as exploitable
Compare your product and version with the public record. A matching version still requires validation against your environment.
Is a vulnerable build present?
Compare these published version ranges with your installed build and any vendor patches.
- Affected versionversion=19184bd06f488af62924ff1747614a8cb284ad63
- Affected versionversion=40a023f681befd9b2862a3c16fb306a38b359ae5
- Affected versionversion=4.14.200 <4.15
- Affected versionversion=4.19.148 <4.20
- Affected versionversion=41b2ea7a6a11e2b1a7f2c29e1675a709a6b2b98d
- Affected versionversion=4.4.238 <4.5
- Affected versionversion=4.9.238 <4.10
- Affected versionversion=5.4.66 <5.5
- Affected versionversion=5.8.10 <5.9
- Affected versionversion=5.9
- Affected versionversion=68c125324b5e1d1d22805653735442923d896a1d
- Affected versionversion=840e124f89a5127e7eb97ebf377f4b8ca745c070
- Affected versionversion=f0dfffce3f4ffd5f822568a4a6fb34c010e939d1
- Affected versionversion=f65886606c2d3b562716de030706dfe1bea4ed5e <03c6cccedd3913006744faa252a4da5145299343
- Affected versionversion=f65886606c2d3b562716de030706dfe1bea4ed5e <2ee3757424be7c1cd1d0bbfa6db29a7edd82a250
- Affected versionversion=f65886606c2d3b562716de030706dfe1bea4ed5e <30f46c6993731efb2a690c9197c0fd9ed425da2d
- Affected versionversion=f65886606c2d3b562716de030706dfe1bea4ed5e <4e899ca848636b37e9ac124bc1723862a7d7d927
What conditions does exploitation require?
What is affected?
Published CVSS scores
CVSS describes severity. EPSS estimates exploitation probability.
Attacks
What attackers are doing with it
Daily unique IPs observed by Shadowserver honeypots for known exploited vulnerabilities (KEVs). Missing observations do not establish an absence of attacks.
Public exploit references
No public exploit references are available in this record.
Labels summarize the accepted research assessment. They do not indicate a test against your environment.
Technologies
Your stack
See the directory against your own environment.
Your stack
Check the software in your environment
Book a demo to see how Hinoki identifies affected software and validates exploitability in your environment.
Book a demo