CVE-2021-46978
published 2024-02-28CVE-2021-46978: In the Linux kernel, the following vulnerability has been resolved: KVM: nVMX: Always make an attempt to map eVMCS after migration When enlightened VMCS is in…
PriorityP337high7.8CVSS 3.1
AVLACLPRLUINSUCHIHAH
EPSS
0.24%
15.4th percentile
In the Linux kernel, the following vulnerability has been resolved:
KVM: nVMX: Always make an attempt to map eVMCS after migration
When enlightened VMCS is in use and nested state is migrated with
vmx_get_nested_state()/vmx_set_nested_state() KVM can't map evmcs
page right away: evmcs gpa is not 'struct kvm_vmx_nested_state_hdr'
and we can't read it from VP assist page because userspace may decide
to restore HV_X64_MSR_VP_ASSIST_PAGE after restoring nested state
(and QEMU, for example, does exactly that). To make sure eVMCS is
mapped /vmx_set_nested_state() raises KVM_REQ_GET_NESTED_STATE_PAGES
request.
Commit f2c7ef3ba955 ("KVM: nSVM: cancel KVM_REQ_GET_NESTED_STATE_PAGES
on nested vmexit") added KVM_REQ_GET_NESTED_STATE_PAGES clearing to
nested_vmx_vmexit() to make sure MSR permission bitmap is not switched
when an immediate exit from L2 to L1 happens right after migration (caused
by a pending event, for example). Unfortunately, in the exact same
situation we still need to have eVMCS mapped so
nested_sync_vmcs12_to_shadow() reflects changes in VMCS12 to eVMCS.
As a band-aid, restore nested_get_evmcs_page() when clearing
KVM_REQ_GET_NESTED_STATE_PAGES in nested_vmx_vmexit(). The 'fix' is far
from being ideal as we can't easily propagate possible failures and even if
we could, this is most likely already too late to do so. The whole
'KVM_REQ_GET_NESTED_STATE_PAGES' idea for mapping eVMCS after migration
seems to be fragile as we diverge too much from the 'native' path when
vmptr loading happens on vmx_set_nested_state().
Affected
15 ranges
| Vendor | Product | Version range | Fixed in |
|---|---|---|---|
| debian | linux | < linux 5.10.38-1 (bookworm) | linux 5.10.38-1 (bookworm) |
| linux | linux | — | — |
| linux | linux | >= 0faceb7d6dda6f370ff1fa0464d7180f7e5cb417 < c8bf64e3fb77cc19bad146fbe26651985b117194 | c8bf64e3fb77cc19bad146fbe26651985b117194 |
| linux | linux | >= 5.10.13 < 5.10.38 | 5.10.38 |
| linux | linux | >= f2c7ef3ba9556d62a7e2bb23b563c6510007d55c < 200a45649ab7361bc80c70aebf7165b64f9a6c9f | 200a45649ab7361bc80c70aebf7165b64f9a6c9f |
| linux | linux | >= f2c7ef3ba9556d62a7e2bb23b563c6510007d55c < bd0e8455b85b651a4c77de9616e307129b15aaa7 | bd0e8455b85b651a4c77de9616e307129b15aaa7 |
| linux | linux | >= f2c7ef3ba9556d62a7e2bb23b563c6510007d55c < f5c7e8425f18fdb9bdb7d13340651d7876890329 | f5c7e8425f18fdb9bdb7d13340651d7876890329 |
| linux | linux_kernel | — | — |
| linux | linux_kernel | >= 0 < 5.10.38-1 | 5.10.38-1 |
| linux | linux_kernel | >= 0 < 5.10.38-1 | 5.10.38-1 |
| linux | linux_kernel | >= 0 < 5.10.38-1 | 5.10.38-1 |
| linux | linux_kernel | >= 0 < 5.10.38-1 | 5.10.38-1 |
| linux | linux_kernel | >= 5.10.13 < 5.10.38 | 5.10.38 |
| linux | linux_kernel | >= 5.11 < 5.11.22 | 5.11.22 |
| linux | linux_kernel | >= 5.12 < 5.12.5 | 5.12.5 |
CVSS provenance
nvdv3.17.8HIGHCVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H
osv7.8HIGH
vendor_debian7.8HIGH
vendor_redhat7.8HIGH
Stop checking back — get the weekly exploitation signal.
Every Monday: what got weaponized or added to CISA KEV in the last seven days — each CVE cross-linked to its PoC, Nuclei template, and detection rule. Free, one email a week, unsubscribe in one click.
GHSA
GHSA-frh6-wfp2-xc99: In the Linux kernel, the following vulnerability has been resolved:
KVM: nVMX: Always make an attempt to map eVMCS after migration
When enlightened
ghsa_unreviewed·2024-02-28
CVE-2021-46978 [HIGH] GHSA-frh6-wfp2-xc99: In the Linux kernel, the following vulnerability has been resolved:
KVM: nVMX: Always make an attempt to map eVMCS after migration
When enlightened
In the Linux kernel, the following vulnerability has been resolved:
KVM: nVMX: Always make an attempt to map eVMCS after migration
When enlightened VMCS is in use and nested state is migrated with
vmx_get_nested_state()/vmx_set_nested_state() KVM can't map evmcs
page right away: evmcs gpa is not 'struct kvm_vmx_nested_state_hdr'
and we can't read it from VP assist page because userspace may decide
to restore HV_X64_MSR_VP_ASSIST_PAGE after restoring nested state
(and QEMU, for example, does exactly that). To make sure eVMCS is
mapped /vmx_set_nested_state() raises KVM_REQ_GET_NESTED_STATE_PAGES
request.
Commit f2c7ef3ba955 ("KVM: nSVM: cancel KVM_REQ_GET_NESTED_STATE_PAGES
on nested vmexit") added KVM_REQ_GET_NESTED_STATE_PAGES clearing to
nested_vmx_vmexit() to make sure MSR permission
OSV
CVE-2021-46978: In the Linux kernel, the following vulnerability has been resolved: KVM: nVMX: Always make an attempt to map eVMCS after migration When enlightened VM
osv·2024-02-28·CVSS 7.8
CVE-2021-46978 [HIGH] CVE-2021-46978: In the Linux kernel, the following vulnerability has been resolved: KVM: nVMX: Always make an attempt to map eVMCS after migration When enlightened VM
In the Linux kernel, the following vulnerability has been resolved: KVM: nVMX: Always make an attempt to map eVMCS after migration When enlightened VMCS is in use and nested state is migrated with vmx_get_nested_state()/vmx_set_nested_state() KVM can't map evmcs page right away: evmcs gpa is not 'struct kvm_vmx_nested_state_hdr' and we can't read it from VP assist page because userspace may decide to restore HV_X64_MSR_VP_ASSIST_PAGE after restoring nested state (and QEMU, for example, does exactly that). To make sure eVMCS is mapped /vmx_set_nested_state() raises KVM_REQ_GET_NESTED_STATE_PAGES request. Commit f2c7ef3ba955 ("KVM: nSVM: cancel KVM_REQ_GET_NESTED_STATE_PAGES on nested vmexit") added KVM_REQ_GET_NESTED_STATE_PAGES clearing to nested_vmx_vmexit() to make sure MSR permission bi
Red Hat
kernel: KVM: nVMX: Always make an attempt to map eVMCS after migration
vendor_redhat·2024-02-28·CVSS 7.8
CVE-2021-46978 [HIGH] CWE-20 kernel: KVM: nVMX: Always make an attempt to map eVMCS after migration
kernel: KVM: nVMX: Always make an attempt to map eVMCS after migration
In the Linux kernel, the following vulnerability has been resolved:
KVM: nVMX: Always make an attempt to map eVMCS after migration
When enlightened VMCS is in use and nested state is migrated with
vmx_get_nested_state()/vmx_set_nested_state() KVM can't map evmcs
page right away: evmcs gpa is not 'struct kvm_vmx_nested_state_hdr'
and we can't read it from VP assist page because userspace may decide
to restore HV_X64_MSR_VP_ASSIST_PAGE after restoring nested state
(and QEMU, for example, does exactly that). To make sure eVMCS is
mapped /vmx_set_nested_state() raises KVM_REQ_GET_NESTED_STATE_PAGES
request.
Commit f2c7ef3ba955 ("KVM: nSVM: cancel KVM_REQ_GET_NESTED_STATE_PAGES
on nested vmexit") added KVM_REQ_GET_NESTED_ST
Debian
CVE-2021-46978: linux - In the Linux kernel, the following vulnerability has been resolved: KVM: nVMX: ...
vendor_debian·2021·CVSS 7.8
CVE-2021-46978 [HIGH] CVE-2021-46978: linux - In the Linux kernel, the following vulnerability has been resolved: KVM: nVMX: ...
In the Linux kernel, the following vulnerability has been resolved: KVM: nVMX: Always make an attempt to map eVMCS after migration When enlightened VMCS is in use and nested state is migrated with vmx_get_nested_state()/vmx_set_nested_state() KVM can't map evmcs page right away: evmcs gpa is not 'struct kvm_vmx_nested_state_hdr' and we can't read it from VP assist page because userspace may decide to restore HV_X64_MSR_VP_ASSIST_PAGE after restoring nested state (and QEMU, for example, does exactly that). To make sure eVMCS is mapped /vmx_set_nested_state() raises KVM_REQ_GET_NESTED_STATE_PAGES request. Commit f2c7ef3ba955 ("KVM: nSVM: cancel KVM_REQ_GET_NESTED_STATE_PAGES on nested vmexit") added KVM_REQ_GET_NESTED_STATE_PAGES clearing to nested_vmx_vmexit() to make sure MSR permission bi
No detection rules found.
No public exploits indexed.
https://git.kernel.org/stable/c/200a45649ab7361bc80c70aebf7165b64f9a6c9fhttps://git.kernel.org/stable/c/bd0e8455b85b651a4c77de9616e307129b15aaa7https://git.kernel.org/stable/c/c8bf64e3fb77cc19bad146fbe26651985b117194https://git.kernel.org/stable/c/f5c7e8425f18fdb9bdb7d13340651d7876890329https://git.kernel.org/stable/c/200a45649ab7361bc80c70aebf7165b64f9a6c9fhttps://git.kernel.org/stable/c/bd0e8455b85b651a4c77de9616e307129b15aaa7https://git.kernel.org/stable/c/c8bf64e3fb77cc19bad146fbe26651985b117194https://git.kernel.org/stable/c/f5c7e8425f18fdb9bdb7d13340651d7876890329
2024-02-28
Published