In the Linux kernel, the following vulnerability has been resolved:
KVM: nVM: Ensure INVVPID is emulated on the correct physical CPU
When emulating INVVPID, KVM executes INVVPID on the physical CPU using
vpid02 (instead of the L1 assigned VPID), after doing some validations
on the operands. However, it is possible that the physical CPU KVM
executes INVVPID on is different from the CPU L2 is running on.
For example, in the following scenario:
- L2 runs on CPU #1 and exits to L1 (vmx->nested.vmcs02.cpu=1)
- L1 migrates to CPU #2 and executes INVVPID
- KVM executes INVVPID on CPU #2
- L1 migrates back to CPU #1 and runs L2 (vmx->nested.vmcs02.cpu=1)
The TLB entries on CPU #1 are never invalidated, because INVVPID was
executed on CPU #2, and vmcs02 never ran on a different pCPU (i.e.
vmx_vcpu_load_vmcs() will not request KVM_REQ_TLB_FLUSH).
Ensure that INVVPID is being executed on the same pCPU that L2 last ran
on, and if not, fallback to clearing last_vpid=0 to trigger a full VPID
flush on the next nested VM-Enter (as KVM will detect L1 using a
different VPID for L2). If L2 ends up running on a different pCPU, KVM
will flush the TLB anyway through vmx_vcpu_load_vmcs().
CVSS Vector: CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:C/C:H/I:H/A:H
CVSS Score: 8.8
AV:L - The bug is reached when an L1 nested VMX guest executes INVVPID, causing a VM-exit handled by handle_invvpid() on the host KVM_RUN ioctl path after VMXON/VMLAUNCH; no network, adjacent-radio, or physical path reaches this nVMX emulator.
AC:L - A kvm-group or nested-virt tenant attacker controls both sides: pin the vCPU, run L2, migrate the vCPU thread with sched_setaffinity, execute INVVPID in L1, then migrate back so L2 resumes on the original pCPU with stale VPID translations; nested=1 and vpid=1 are defaults.
PR:L - Exploitation needs /dev/kvm (kvm-group) or a cloud tenant VM with nested virtualization, plus CPL=0 in L1 after VMXON to execute INVVPID; KVM create/run ioctls have no CAP_SYS_ADMIN gate, and init-namespace host root is not required.
UI:N - The attacker issues INVVPID from their own nested hypervisor and migrates the vCPU themselves; no separate victim action such as mounting a filesystem or opening a crafted file is required.
S:C - Missed INVVPID leaves L2's VPID-tagged combined GVA-to-HPA TLB entries live on the pCPU where L2 last ran, so L2 can access host physical pages after L1 revoked those mappings, crossing the nested-guest versus L1-hypervisor and potentially guest-to-host isolation boundary.
C:H - Stale combined mappings let L2 read host physical memory that L1 unmapped or reassigned to L1 or a sibling L2, and with page reuse those frames may hold other-guest or host data, yielding cross-VM information disclosure rather than a bounded leak.
I:H - The retained TLB entries remain writable, so L2 can write through stale translations into remapped or recycled pages including L1 hypervisor memory, giving an arbitrary-write primitive consistent with missed-TLB and nested isolation-bypass scoring.
A:H - Writes through stale VPID mappings into reused L1, sibling-guest, or host pages corrupt hypervisor or kernel state and can oops or panic the nested hypervisor or host, fully denying availability to co-resident VMs.
| Attack Vector |
Local |
Scope |
Changed |
| Attack Complexity |
Low |
Confidentiality Impact |
High |
| Privileges Required |
Low |
Integrity Impact |
High |
| User Interaction |
None |
Availability Impact |
High |
AV:L - The bug is reached when an L1 nested VMX guest executes INVVPID, causing a VM-exit handled by handle_invvpid() on the host KVM_RUN ioctl path after VMXON/VMLAUNCH; no network, adjacent-radio, or physical path reaches this nVMX emulator.
AC:L - A kvm-group or nested-virt tenant attacker controls both sides: pin the vCPU, run L2, migrate the vCPU thread with sched_setaffinity, execute INVVPID in L1, then migrate back so L2 resumes on the original pCPU with stale VPID translations; nested=1 and vpid=1 are defaults.
PR:L - Exploitation needs /dev/kvm (kvm-group) or a cloud tenant VM with nested virtualization, plus CPL=0 in L1 after VMXON to execute INVVPID; KVM create/run ioctls have no CAP_SYS_ADMIN gate, and init-namespace host root is not required.
UI:N - The attacker issues INVVPID from their own nested hypervisor and migrates the vCPU themselves; no separate victim action such as mounting a filesystem or opening a crafted file is required.
S:C - Missed INVVPID leaves L2's VPID-tagged combined GVA-to-HPA TLB entries live on the pCPU where L2 last ran, so L2 can access host physical pages after L1 revoked those mappings, crossing the nested-guest versus L1-hypervisor and potentially guest-to-host isolation boundary.
C:H - Stale combined mappings let L2 read host physical memory that L1 unmapped or reassigned to L1 or a sibling L2, and with page reuse those frames may hold other-guest or host data, yielding cross-VM information disclosure rather than a bounded leak.
I:H - The retained TLB entries remain writable, so L2 can write through stale translations into remapped or recycled pages including L1 hypervisor memory, giving an arbitrary-write primitive consistent with missed-TLB and nested isolation-bypass scoring.
A:H - Writes through stale VPID mappings into reused L1, sibling-guest, or host pages corrupt hypervisor or kernel state and can oops or panic the nested hypervisor or host, fully denying availability to co-resident VMs.
CVSS 3.1