CVE-2026-45987: KVM: nSVM: Sync interrupt shadow to cached vmcb12 after VMRUN of L2
In the Linux kernel, the following vulnerability has been resolved:
KVM: nSVM: Sync interrupt shadow to cached vmcb12 after VMRUN of L2
After VMRUN in guest mode, nestedsynccontrolfromvmcb02() syncs fields written by the CPU from vmcb02 to the cached vmcb12. This is because the cached vmcb12 is used as the authoritative copy of some of the controls, and is the payload when saving/restoring nested state.
intstate is also written by the CPU, specifically bit 0 (i.e. SVMINTERRUPTSHADOWMASK) for nested VMs, but it is not sync'd to cached vmcb12. This does not cause a problem if KVMSETNESTEDSTATE preceeds KVMSETVCPUEVENTS in the restore path, as an interrupt shadow would be correctly restored to vmcb02 (KVMSETVCPUEVENTS overwrites what KVMSETNESTEDSTATE restored in intstate).
However, if KVMSETVCPUEVENTS preceeds KVMSETNESTEDSTATE, an interrupt shadow would be restored into vmcb01 instead of vmcb02. This would mostly be benign for L1 (delays an interrupt), but not for L2. For L2, the vCPU could hang (e.g. if a wakeup interrupt is delivered before a HLT that should have been in an interrupt shadow).
Sync intstate to the cached vmcb12 in nestedsynccontrolfromvmcb02() to avoid this problem. With that, KVMSETNESTEDSTATE restores the correct interrupt shadow state, and if KVMSETVCPUEVENTS follows it would overwrite it with the same value.
Affected Software
Remediation
Recommended actions to resolve this vulnerability, in priority order.
- Upgrade
Upgrade to a fixed release to a version that resolves this vulnerability.
Fixed in 6.6.141.1-1
Event History
Frequently Asked Questions
Which deployments face the meaningful impact?
Systems using KVM nested SVM virtualization are affected in the described restore scenario. The harmful outcome is specific to an L2 nested guest, where the vCPU can hang; the corresponding effect for L1 is described as mostly benign interrupt delay.
What conditions are needed to trigger the issue?
Exploitation requires local access with low privileges, as reflected by the AV:L and PR:L vector. The triggering condition described is a restore path in which KVM_SET_VCPU_EVENTS is performed before KVM_SET_NESTED_STATE, causing the interrupt shadow to be restored into vmcb01 rather than vmcb02.
How might an affected system present?
A likely indication is an L2 vCPU hang during nested-VM state restoration, particularly when a wakeup interrupt is delivered before a HLT that should have been protected by an interrupt shadow. The provided information does not describe a broader detection method or configuration check.