Bug 2267171 (CVE-2021-47062)

Summary: CVE-2021-47062 kernel: KVM: SVM: null pointer in online_vcpus, not created_vcpus, to iterate over vCPUs
Product: [Other] Security Response Reporter: Avinash Hanwate <ahanwate>
Component: vulnerabilityAssignee: Product Security <prodsec-ir-bot>
Status: NEW --- QA Contact:
Severity: medium Docs Contact:
Priority: medium    
Version: unspecifiedCC: acaringi, allarkin, aquini, bhu, chwhite, cye, cyin, dbohanno, debarbos, dfreiber, drow, dvlasenk, esandeen, ezulian, hkrzesin, jarod, jburrell, jdenham, jfaracco, jforbes, jlelli, joe.lawrence, jshortt, jstancek, jwyatt, kcarcia, ldoskova, lgoncalv, lzampier, mleitner, mmilgram, mstowell, nmurray, ptalbert, rparrazo, rrobaina, rvrbovsk, scweaver, sidakwo, sukulkar, tglozar, vkumar, wcosta, williams, wmealing, ycote, ykopkova, zhijwang
Target Milestone: ---Keywords: Security
Target Release: ---   
Hardware: All   
OS: Linux   
Whiteboard:
Fixed In Version: kernel 5.11.21, kernel 5.12.4, kernel 5.13 Doc Type: If docs needed, set a value
Doc Text:
A flaw was found in the Linux kernel's Kernel-based virtual machine (KVM) subsystem for AMD's Secure virtual machine (SVM). The issue occurs when using the created_vcpus list to iterate over vCPUs instead of the online_vcpus list, leading to a possible NULL pointer dereference. This vulnerability impacts the encryption of Virtual Machine Save Areas (VMSAs) for Secure Encrypted Virtualization (SEV).
Story Points: ---
Clone Of: Environment:
Last Closed: Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Bug Depends On: 2267172    
Bug Blocks: 2267188    

Description Avinash Hanwate 2024-03-01 04:56:39 UTC
In the Linux kernel, the following vulnerability has been resolved:

KVM: SVM: Use online_vcpus, not created_vcpus, to iterate over vCPUs

The Linux kernel CVE team has assigned CVE-2021-47062 to this issue.

Upstream advisory:
https://lore.kernel.org/linux-cve-announce/2024022953-CVE-2021-47062-ed39@gregkh/T/#u

Comment 1 Avinash Hanwate 2024-03-01 04:57:18 UTC
Created kernel tracking bugs for this issue:

Affects: fedora-all [bug 2267172]

Comment 5 Justin M. Forbes 2024-03-01 21:09:21 UTC
This was fixed for Fedora with the 5.12.4 stable kernel updates.

Comment 7 Alex 2024-06-09 15:04:58 UTC
The result of automatic check (that is developed by Alexander Larkin) for this CVE-2021-47062 is: CHECK	Maybe valid. Check manually. with impact MODERATE (that is approximation based on flags VIRT SIMPLEFIX  ; these flags parsed automatically based on patche data). Such automatic check happens only for Low/Moderates (and only when not from reporter, but parsing already existing CVE). Highs always checked manually (I check it myself and then we check it again in Remediation team). In rare cases some of the Moderates could be increased to High later.