From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from smtp.kernel.org (aws-us-west-2-korg-mail-1.web.codeaurora.org [10.30.226.201]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 3EF7F3E3177 for ; Fri, 8 May 2026 13:15:15 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=10.30.226.201 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1778246115; cv=none; b=ki4DO1ECAV7qEU1csThEHkHbgljvYdEs6mmN2NEVwGF1C30TZ07wou7OGrk0ocdJxw0HEvNHXUZh0S4hk0HAHqrHC7MSh9cooG6WezKb/r5fyRcpZ+IcvTqmEWarHlhADJA37edNYOG3fpploWuhSnXFYogEEZeGdeIoqaoD74Y= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1778246115; c=relaxed/simple; bh=BRGtyJsFPwwj0zfXNhfMqFEKJL4i9cQaoJSwg8Z+cSo=; h=From:To:Cc:Subject:Date:Message-ID:MIME-Version; b=fIgoB5HO4kjDUW9KuyjMwmatvCgOj3pzBlfcMqVfMlU/b0dibI1OS2yXb5fc5W/+MakUkv3IacGPJJEenXG+R8z7GWdo39j219V0Clv/u+X3UDnHv7xCpPFwivq/TVL5fajpNYw2xA81NPxg15955yfjknjOXFapoHytXtKrq0Q= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.b=YC8evYiI; arc=none smtp.client-ip=10.30.226.201 Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.b="YC8evYiI" Received: by smtp.kernel.org (Postfix) with ESMTPSA id C96F2C2BCB0; Fri, 8 May 2026 13:15:14 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1778246115; bh=BRGtyJsFPwwj0zfXNhfMqFEKJL4i9cQaoJSwg8Z+cSo=; h=From:To:Cc:Subject:Date:Reply-To:From; b=YC8evYiI2KwcJY0y69JmTKDlCPsmC5qdsj45Ei3EOmFumXB6/LRnV8jt3HHTNCpBN kMKxQ1YCdEPVlfQXmSSFbpaCIYMQyGXnJypuWXMy8VHKMaGEM4XVo5ibSZ0dsbAfGM okm9ey6pdDBZtnT+AL4rwHG8OFiD3fvAb0iabLPY= From: Greg Kroah-Hartman To: linux-cve-announce@vger.kernel.org Cc: Greg Kroah-Hartman Subject: CVE-2026-43315: KVM: nSVM: Remove a user-triggerable WARN on nested_svm_load_cr3() succeeding Date: Fri, 8 May 2026 15:12:20 +0200 Message-ID: <2026050801-CVE-2026-43315-3359@gregkh> X-Mailer: git-send-email 2.54.0 Reply-To: , Precedence: bulk X-Mailing-List: linux-cve-announce@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 X-Developer-Signature: v=1; a=openpgp-sha256; l=5231; i=gregkh@linuxfoundation.org; h=from:subject:message-id; bh=pZV6Ywi2/wj4l5V7KosXFm3+Y05sC+ydeTr9HDXzv+4=; b=owGbwMvMwCRo6H6F97bub03G02pJDJl/Hyqmcd0LDJkya96JfQIpm9+x3L+xoGbySSaxNT9zm Y1FlppXdsSyMAgyMciKKbJ82cZzdH/FIUUvQ9vTMHNYmUCGMHBxCsBEJpYyzDPivqodJWPEYhsb kBT5tXO9tkD2fIYFB8/ETDBerFLk9DTWudbwVwVvwdUDAA== X-Developer-Key: i=gregkh@linuxfoundation.org; a=openpgp; fpr=F4B60CC5BF78C2214A313DCB3147D40DDB2DFB29 Content-Transfer-Encoding: 8bit From: Greg Kroah-Hartman Description =========== In the Linux kernel, the following vulnerability has been resolved: KVM: nSVM: Remove a user-triggerable WARN on nested_svm_load_cr3() succeeding Drop the WARN in svm_set_nested_state() on nested_svm_load_cr3() failing as it is trivially easy to trigger from userspace by modifying CPUID after loading CR3. E.g. modifying the state restoration selftest like so: --- tools/testing/selftests/kvm/x86/state_test.c +++ tools/testing/selftests/kvm/x86/state_test.c @@ -280,7 +280,16 @@ int main(int argc, char *argv[]) /* Restore state in a new VM. */ vcpu = vm_recreate_with_one_vcpu(vm); - vcpu_load_state(vcpu, state); + + if (stage == 4) { + state->sregs.cr3 = BIT(44); + vcpu_load_state(vcpu, state); + + vcpu_set_cpuid_property(vcpu, X86_PROPERTY_MAX_PHY_ADDR, 36); + __vcpu_nested_state_set(vcpu, &state->nested); + } else { + vcpu_load_state(vcpu, state); + } /* * Restore XSAVE state in a dummy vCPU, first without doing generates: WARNING: CPU: 30 PID: 938 at arch/x86/kvm/svm/nested.c:1877 svm_set_nested_state+0x34a/0x360 [kvm_amd] Modules linked in: kvm_amd kvm irqbypass [last unloaded: kvm] CPU: 30 UID: 1000 PID: 938 Comm: state_test Tainted: G W 6.18.0-rc7-58e10b63777d-next-vm Tainted: [W]=WARN Hardware name: QEMU Standard PC (Q35 + ICH9, 2009), BIOS 0.0.0 02/06/2015 RIP: 0010:svm_set_nested_state+0x34a/0x360 [kvm_amd] Call Trace: kvm_arch_vcpu_ioctl+0xf33/0x1700 [kvm] kvm_vcpu_ioctl+0x4e6/0x8f0 [kvm] __x64_sys_ioctl+0x8f/0xd0 do_syscall_64+0x61/0xad0 entry_SYSCALL_64_after_hwframe+0x4b/0x53 Simply delete the WARN instead of trying to prevent userspace from shoving "illegal" state into CR3. For better or worse, KVM's ABI allows userspace to set CPUID after SREGS, and vice versa, and KVM is very permissive when it comes to guest CPUID. I.e. attempting to enforce the virtual CPU model when setting CPUID could break userspace. Given that the WARN doesn't provide any meaningful protection for KVM or benefit for userspace, simply drop it even though the odds of breaking userspace are minuscule. Opportunistically delete a spurious newline. The Linux kernel CVE team has assigned CVE-2026-43315 to this issue. Affected and fixed versions =========================== Issue introduced in 5.14 with commit b222b0b88162bdef4eceb12a79d5edbbdb23dbfd and fixed in 5.15.202 with commit 155ec243ef726f4bc49536fa0bfb565dc011ab17 Issue introduced in 5.14 with commit b222b0b88162bdef4eceb12a79d5edbbdb23dbfd and fixed in 6.1.165 with commit 580ea57840864d40e019bc13fd26afdc8d510a2f Issue introduced in 5.14 with commit b222b0b88162bdef4eceb12a79d5edbbdb23dbfd and fixed in 6.6.128 with commit deb8f6dfd31d94b18dbeeaa8c01fbec5fc70fd2b Issue introduced in 5.14 with commit b222b0b88162bdef4eceb12a79d5edbbdb23dbfd and fixed in 6.12.75 with commit ce904c8a5bbe697eae0f7e34b07095bd7a6dee19 Issue introduced in 5.14 with commit b222b0b88162bdef4eceb12a79d5edbbdb23dbfd and fixed in 6.18.16 with commit 969e5e13ff5c18603f21d1f9f64ec9194e141ac0 Issue introduced in 5.14 with commit b222b0b88162bdef4eceb12a79d5edbbdb23dbfd and fixed in 6.19.6 with commit ebb2ab4f1c87d6b52776292cf7dc16aea48e95f8 Issue introduced in 5.14 with commit b222b0b88162bdef4eceb12a79d5edbbdb23dbfd and fixed in 7.0 with commit fc3ba56385d03501eb582e4b86691ba378e556f9 Please see https://www.kernel.org for a full list of currently supported kernel versions by the kernel community. Unaffected versions might change over time as fixes are backported to older supported kernel versions. The official CVE entry at https://cve.org/CVERecord/?id=CVE-2026-43315 will be updated if fixes are backported, please check that for the most up to date information about this issue. Affected files ============== The file(s) affected by this issue are: arch/x86/kvm/svm/nested.c Mitigation ========== The Linux kernel CVE team recommends that you update to the latest stable kernel version for this, and many other bugfixes. Individual changes are never tested alone, but rather are part of a larger kernel release. Cherry-picking individual commits is not recommended or supported by the Linux kernel community at all. If however, updating to the latest release is impossible, the individual changes to resolve this issue can be found at these commits: https://git.kernel.org/stable/c/155ec243ef726f4bc49536fa0bfb565dc011ab17 https://git.kernel.org/stable/c/580ea57840864d40e019bc13fd26afdc8d510a2f https://git.kernel.org/stable/c/deb8f6dfd31d94b18dbeeaa8c01fbec5fc70fd2b https://git.kernel.org/stable/c/ce904c8a5bbe697eae0f7e34b07095bd7a6dee19 https://git.kernel.org/stable/c/969e5e13ff5c18603f21d1f9f64ec9194e141ac0 https://git.kernel.org/stable/c/ebb2ab4f1c87d6b52776292cf7dc16aea48e95f8 https://git.kernel.org/stable/c/fc3ba56385d03501eb582e4b86691ba378e556f9