CVE-2021-47062: Vulnerability in Linux Linux
In the Linux kernel, the following vulnerability has been resolved: KVM: SVM: Use online_vcpus, not created_vcpus, to iterate over vCPUs Use the kvm_for_each_vcpu() helper to iterate over vCPUs when encrypting VMSAs for SEV, which effectively switches to use online_vcpus instead of created_vcpus. This fixes a possible null-pointer dereference as created_vcpus does not guarantee a vCPU exists, since it is updated at the very beginning of KVM_CREATE_VCPU. created_vcpus exists to allow the bulk of vCPU creation to run in parallel, while still correctly restricting the max number of max vCPUs.
AI Analysis
Technical Summary
CVE-2021-47062 is a vulnerability identified in the Linux kernel's KVM (Kernel-based Virtual Machine) subsystem, specifically related to the Secure Encrypted Virtualization (SEV) feature that leverages AMD's Secure Virtual Machine (SVM) technology. The issue arises from improper iteration over virtual CPUs (vCPUs) during the encryption of Virtual Machine Save Areas (VMSAs) for SEV. The vulnerable code used the 'created_vcpus' list to iterate over vCPUs, which does not guarantee that a vCPU actually exists because 'created_vcpus' is updated early in the vCPU creation process and may include entries for vCPUs not yet fully initialized. This can lead to a null-pointer dereference when the code attempts to access vCPU structures that are not yet valid. The fix involves switching to use 'online_vcpus' via the helper function 'kvm_for_each_vcpu()', which iterates only over vCPUs that are fully online and operational, thus preventing the null-pointer dereference. This vulnerability is a memory safety issue that could cause a kernel crash (denial of service) or potentially be leveraged for privilege escalation if exploited in combination with other vulnerabilities. However, there are no known exploits in the wild at this time, and the vulnerability requires conditions related to KVM and SEV usage, which are typically found in virtualized environments running Linux kernels with AMD SEV support.
Potential Impact
For European organizations, the impact of CVE-2021-47062 primarily concerns environments utilizing Linux-based virtualization with AMD SEV technology, such as cloud service providers, data centers, and enterprises running private clouds or virtualized infrastructure. A successful exploitation could cause kernel crashes leading to denial of service of virtual machines, impacting availability of critical services. In more complex attack scenarios, it might be used as a stepping stone for privilege escalation within virtualized environments, potentially compromising confidentiality and integrity of hosted workloads. Organizations relying on virtualized infrastructure for sensitive data processing or critical applications could face operational disruptions and increased risk of data breaches if this vulnerability is exploited. Given the lack of known exploits, the immediate risk is moderate, but the vulnerability should be addressed promptly to prevent future exploitation, especially in sectors like finance, healthcare, and government where virtualization is prevalent and data sensitivity is high.
Mitigation Recommendations
To mitigate CVE-2021-47062, European organizations should: 1) Apply the latest Linux kernel patches that address this vulnerability as soon as they become available, ensuring that the KVM subsystem uses 'online_vcpus' for iteration. 2) Audit and update virtualization infrastructure to confirm that AMD SEV features are used securely and that hypervisors are running updated kernel versions. 3) Implement strict access controls and monitoring on virtualization hosts to detect unusual behavior or crashes that might indicate exploitation attempts. 4) Employ kernel hardening techniques and runtime protections such as Kernel Address Space Layout Randomization (KASLR) and Kernel Page-Table Isolation (KPTI) to reduce exploitation likelihood. 5) Regularly review and test backup and recovery procedures to minimize downtime in case of denial of service. 6) Coordinate with cloud providers to verify that their infrastructure is patched if using virtualized services. These steps go beyond generic advice by focusing on the specific virtualization and SEV context of the vulnerability.
Affected Countries
Germany, France, United Kingdom, Netherlands, Sweden, Finland, Italy, Spain
CVE-2021-47062: Vulnerability in Linux Linux
Description
In the Linux kernel, the following vulnerability has been resolved: KVM: SVM: Use online_vcpus, not created_vcpus, to iterate over vCPUs Use the kvm_for_each_vcpu() helper to iterate over vCPUs when encrypting VMSAs for SEV, which effectively switches to use online_vcpus instead of created_vcpus. This fixes a possible null-pointer dereference as created_vcpus does not guarantee a vCPU exists, since it is updated at the very beginning of KVM_CREATE_VCPU. created_vcpus exists to allow the bulk of vCPU creation to run in parallel, while still correctly restricting the max number of max vCPUs.
AI-Powered Analysis
Technical Analysis
CVE-2021-47062 is a vulnerability identified in the Linux kernel's KVM (Kernel-based Virtual Machine) subsystem, specifically related to the Secure Encrypted Virtualization (SEV) feature that leverages AMD's Secure Virtual Machine (SVM) technology. The issue arises from improper iteration over virtual CPUs (vCPUs) during the encryption of Virtual Machine Save Areas (VMSAs) for SEV. The vulnerable code used the 'created_vcpus' list to iterate over vCPUs, which does not guarantee that a vCPU actually exists because 'created_vcpus' is updated early in the vCPU creation process and may include entries for vCPUs not yet fully initialized. This can lead to a null-pointer dereference when the code attempts to access vCPU structures that are not yet valid. The fix involves switching to use 'online_vcpus' via the helper function 'kvm_for_each_vcpu()', which iterates only over vCPUs that are fully online and operational, thus preventing the null-pointer dereference. This vulnerability is a memory safety issue that could cause a kernel crash (denial of service) or potentially be leveraged for privilege escalation if exploited in combination with other vulnerabilities. However, there are no known exploits in the wild at this time, and the vulnerability requires conditions related to KVM and SEV usage, which are typically found in virtualized environments running Linux kernels with AMD SEV support.
Potential Impact
For European organizations, the impact of CVE-2021-47062 primarily concerns environments utilizing Linux-based virtualization with AMD SEV technology, such as cloud service providers, data centers, and enterprises running private clouds or virtualized infrastructure. A successful exploitation could cause kernel crashes leading to denial of service of virtual machines, impacting availability of critical services. In more complex attack scenarios, it might be used as a stepping stone for privilege escalation within virtualized environments, potentially compromising confidentiality and integrity of hosted workloads. Organizations relying on virtualized infrastructure for sensitive data processing or critical applications could face operational disruptions and increased risk of data breaches if this vulnerability is exploited. Given the lack of known exploits, the immediate risk is moderate, but the vulnerability should be addressed promptly to prevent future exploitation, especially in sectors like finance, healthcare, and government where virtualization is prevalent and data sensitivity is high.
Mitigation Recommendations
To mitigate CVE-2021-47062, European organizations should: 1) Apply the latest Linux kernel patches that address this vulnerability as soon as they become available, ensuring that the KVM subsystem uses 'online_vcpus' for iteration. 2) Audit and update virtualization infrastructure to confirm that AMD SEV features are used securely and that hypervisors are running updated kernel versions. 3) Implement strict access controls and monitoring on virtualization hosts to detect unusual behavior or crashes that might indicate exploitation attempts. 4) Employ kernel hardening techniques and runtime protections such as Kernel Address Space Layout Randomization (KASLR) and Kernel Page-Table Isolation (KPTI) to reduce exploitation likelihood. 5) Regularly review and test backup and recovery procedures to minimize downtime in case of denial of service. 6) Coordinate with cloud providers to verify that their infrastructure is patched if using virtualized services. These steps go beyond generic advice by focusing on the specific virtualization and SEV context of the vulnerability.
Affected Countries
For access to advanced analysis and higher rate limits, contact root@offseq.com
Technical Details
- Data Version
- 5.1
- Assigner Short Name
- Linux
- Date Reserved
- 2024-02-29T22:33:44.294Z
- Cisa Enriched
- true
- Cvss Version
- null
- State
- PUBLISHED
Threat ID: 682d9834c4522896dcbe9beb
Added to database: 5/21/2025, 9:09:08 AM
Last enriched: 6/30/2025, 8:40:29 PM
Last updated: 8/16/2025, 1:49:58 AM
Views: 16
Related Threats
CVE-2025-9091: Hard-coded Credentials in Tenda AC20
LowCVE-2025-9090: Command Injection in Tenda AC20
MediumCVE-2025-9092: CWE-400 Uncontrolled Resource Consumption in Legion of the Bouncy Castle Inc. Bouncy Castle for Java - BC-FJA 2.1.0
LowCVE-2025-9089: Stack-based Buffer Overflow in Tenda AC20
HighCVE-2025-9088: Stack-based Buffer Overflow in Tenda AC20
HighActions
Updates to AI analysis are available only with a Pro account. Contact root@offseq.com for access.
External Links
Need enhanced features?
Contact root@offseq.com for Pro access with improved analysis and higher rate limits.