{
    "dataType": "CVE_RECORD",
    "dataVersion": "5.2",
    "cveMetadata": {
        "cveId": "CVE-2025-37957",
        "assignerOrgId": "416baaa9-dc9f-4396-8d5f-8c081fb06d67",
        "state": "PUBLISHED",
        "assignerShortName": "Linux",
        "dateReserved": "2025-04-16T04:51:23.974Z",
        "datePublished": "2025-05-20T16:01:50.878Z",
        "dateUpdated": "2026-08-05T11:58:39.331Z"
    },
    "containers": {
        "cna": {
            "providerMetadata": {
                "orgId": "416baaa9-dc9f-4396-8d5f-8c081fb06d67",
                "shortName": "Linux",
                "dateUpdated": "2026-08-05T11:58:39.331Z"
            },
            "descriptions": [
                {
                    "lang": "en",
                    "value": "In the Linux kernel, the following vulnerability has been resolved:\n\nKVM: SVM: Forcibly leave SMM mode on SHUTDOWN interception\n\nPreviously, commit ed129ec9057f (\"KVM: x86: forcibly leave nested mode\non vCPU reset\") addressed an issue where a triple fault occurring in\nnested mode could lead to use-after-free scenarios. However, the commit\ndid not handle the analogous situation for System Management Mode (SMM).\n\nThis omission results in triggering a WARN when KVM forces a vCPU INIT\nafter SHUTDOWN interception while the vCPU is in SMM. This situation was\nreprodused using Syzkaller by:\n\n  1) Creating a KVM VM and vCPU\n  2) Sending a KVM_SMI ioctl to explicitly enter SMM\n  3) Executing invalid instructions causing consecutive exceptions and\n     eventually a triple fault\n\nThe issue manifests as follows:\n\n  WARNING: CPU: 0 PID: 25506 at arch/x86/kvm/x86.c:12112\n  kvm_vcpu_reset+0x1d2/0x1530 arch/x86/kvm/x86.c:12112\n  Modules linked in:\n  CPU: 0 PID: 25506 Comm: syz-executor.0 Not tainted\n  6.1.130-syzkaller-00157-g164fe5dde9b6 #0\n  Hardware name: QEMU Standard PC (i440FX + PIIX, 1996),\n  BIOS 1.12.0-1 04/01/2014\n  RIP: 0010:kvm_vcpu_reset+0x1d2/0x1530 arch/x86/kvm/x86.c:12112\n  Call Trace:\n   <TASK>\n   shutdown_interception+0x66/0xb0 arch/x86/kvm/svm/svm.c:2136\n   svm_invoke_exit_handler+0x110/0x530 arch/x86/kvm/svm/svm.c:3395\n   svm_handle_exit+0x424/0x920 arch/x86/kvm/svm/svm.c:3457\n   vcpu_enter_guest arch/x86/kvm/x86.c:10959 [inline]\n   vcpu_run+0x2c43/0x5a90 arch/x86/kvm/x86.c:11062\n   kvm_arch_vcpu_ioctl_run+0x50f/0x1cf0 arch/x86/kvm/x86.c:11283\n   kvm_vcpu_ioctl+0x570/0xf00 arch/x86/kvm/../../../virt/kvm/kvm_main.c:4122\n   vfs_ioctl fs/ioctl.c:51 [inline]\n   __do_sys_ioctl fs/ioctl.c:870 [inline]\n   __se_sys_ioctl fs/ioctl.c:856 [inline]\n   __x64_sys_ioctl+0x19a/0x210 fs/ioctl.c:856\n   do_syscall_x64 arch/x86/entry/common.c:51 [inline]\n   do_syscall_64+0x35/0x80 arch/x86/entry/common.c:81\n   entry_SYSCALL_64_after_hwframe+0x6e/0xd8\n\nArchitecturally, INIT is blocked when the CPU is in SMM, hence KVM's WARN()\nin kvm_vcpu_reset() to guard against KVM bugs, e.g. to detect improper\nemulation of INIT.  SHUTDOWN on SVM is a weird edge case where KVM needs to\ndo _something_ sane with the VMCB, since it's technically undefined, and\nINIT is the least awful choice given KVM's ABI.\n\nSo, double down on stuffing INIT on SHUTDOWN, and force the vCPU out of\nSMM to avoid any weirdness (and the WARN).\n\nFound by Linux Verification Center (linuxtesting.org) with Syzkaller.\n\n[sean: massage changelog, make it clear this isn't architectural behavior]"
                }
            ],
            "metrics": [
                {
                    "cvssV3_1": {
                        "version": "3.1",
                        "vectorString": "CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:C/C:H/I:H/A:H",
                        "baseScore": 8.8,
                        "baseSeverity": "HIGH"
                    },
                    "scenarios": [
                        {
                            "lang": "en",
                            "value": "AV:L - The vulnerability is reached through the local KVM device interface (`KVM_SMI` + `KVM_RUN` ioctls on /dev/kvm) or by code executing inside a guest VM on the local host; no network protocol handling is involved.\nAC:L - The trigger is fully deterministic and attacker-controlled — enter SMM, then execute instructions that cause consecutive faults until a triple fault, which unconditionally hits the SHUTDOWN intercept; syzkaller reproduced it reliably with no race or memory-layout dependency.\nPR:L - The attacker needs only access to /dev/kvm (routinely granted to the unprivileged `kvm` group and to sandboxed VMM processes such as QEMU), or ring-0 in a guest to write the LAPIC ICR with SMI delivery mode; no root or CAP_SYS_ADMIN in the init namespace is required.\nUI:N - The attacker performs the entire sequence itself via ioctls or guest instruction execution; no action by any other user or administrator is needed.\nS:C - The attacker is confined to a VM/VMM sandbox, but the corrupted state lives in the host kernel's KVM MMU, so the impact escapes that confinement to the host and to other guests on the same host; the stale `smm=1` root additionally breaches the SMM/SMRAM boundary the VMM enforces.\nC:H - The vCPU resumes with an MMU root tagged for the SMM address space while KVM believes it is not in SMM, granting the guest read access to SMRAM and leaving address-space-mismatched SPTEs that slot-scoped zaps never invalidate, yielding dangling read mappings into freed host pages.\nI:H - The same address-space-confused SPTEs are writable, so the guest can write to SMRAM (defeating firmware/secure-boot protections) and to host pages that have been freed or migrated away, providing a host memory write primitive.\nA:H - The WARN_ON_ONCE in kvm_vcpu_reset() is hit on demand, which is an immediate host kernel panic on the widely deployed `panic_on_warn=1` hardened configuration, and the resulting inconsistent vCPU/MMU state can crash the host independently."
                        }
                    ]
                }
            ],
            "affected": [
                {
                    "product": "Linux",
                    "vendor": "Linux",
                    "defaultStatus": "unaffected",
                    "repo": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git",
                    "programFiles": [
                        "arch/x86/kvm/smm.c",
                        "arch/x86/kvm/svm/svm.c"
                    ],
                    "versions": [
                        {
                            "version": "ed129ec9057f89d615ba0c81a4984a90345a1684",
                            "lessThan": "ec24e62a1dd3540ee696314422040180040c1e4a",
                            "status": "affected",
                            "versionType": "git"
                        },
                        {
                            "version": "ed129ec9057f89d615ba0c81a4984a90345a1684",
                            "lessThan": "d362b21fefcef7eda8f1cd78a5925735d2b3287c",
                            "status": "affected",
                            "versionType": "git"
                        },
                        {
                            "version": "ed129ec9057f89d615ba0c81a4984a90345a1684",
                            "lessThan": "e9b28bc65fd3a56755ba503258024608292b4ab1",
                            "status": "affected",
                            "versionType": "git"
                        },
                        {
                            "version": "ed129ec9057f89d615ba0c81a4984a90345a1684",
                            "lessThan": "a2620f8932fa9fdabc3d78ed6efb004ca409019f",
                            "status": "affected",
                            "versionType": "git"
                        },
                        {
                            "version": "6425c590d0cc6914658a630a40b7f8226aa028c3",
                            "status": "affected",
                            "versionType": "git"
                        },
                        {
                            "version": "d40ef0a511676bd65ca9acb295430c07af59ab85",
                            "status": "affected",
                            "versionType": "git"
                        },
                        {
                            "version": "5.15.81",
                            "lessThan": "5.16",
                            "status": "affected",
                            "versionType": "semver"
                        },
                        {
                            "version": "6.0.11",
                            "lessThan": "6.1",
                            "status": "affected",
                            "versionType": "semver"
                        }
                    ]
                },
                {
                    "product": "Linux",
                    "vendor": "Linux",
                    "defaultStatus": "affected",
                    "repo": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git",
                    "programFiles": [
                        "arch/x86/kvm/smm.c",
                        "arch/x86/kvm/svm/svm.c"
                    ],
                    "versions": [
                        {
                            "version": "6.1",
                            "status": "affected"
                        },
                        {
                            "version": "0",
                            "lessThan": "6.1",
                            "status": "unaffected",
                            "versionType": "semver"
                        },
                        {
                            "version": "6.6.92",
                            "lessThanOrEqual": "6.6.*",
                            "status": "unaffected",
                            "versionType": "semver"
                        },
                        {
                            "version": "6.12.29",
                            "lessThanOrEqual": "6.12.*",
                            "status": "unaffected",
                            "versionType": "semver"
                        },
                        {
                            "version": "6.14.7",
                            "lessThanOrEqual": "6.14.*",
                            "status": "unaffected",
                            "versionType": "semver"
                        },
                        {
                            "version": "6.15",
                            "lessThanOrEqual": "*",
                            "status": "unaffected",
                            "versionType": "original_commit_for_fix"
                        }
                    ]
                }
            ],
            "cpeApplicability": [
                {
                    "nodes": [
                        {
                            "operator": "OR",
                            "negate": false,
                            "cpeMatch": [
                                {
                                    "vulnerable": true,
                                    "criteria": "cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*",
                                    "versionStartIncluding": "6.1",
                                    "versionEndExcluding": "6.6.92"
                                },
                                {
                                    "vulnerable": true,
                                    "criteria": "cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*",
                                    "versionStartIncluding": "6.1",
                                    "versionEndExcluding": "6.12.29"
                                },
                                {
                                    "vulnerable": true,
                                    "criteria": "cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*",
                                    "versionStartIncluding": "6.1",
                                    "versionEndExcluding": "6.14.7"
                                },
                                {
                                    "vulnerable": true,
                                    "criteria": "cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*",
                                    "versionStartIncluding": "6.1",
                                    "versionEndExcluding": "6.15"
                                },
                                {
                                    "vulnerable": true,
                                    "criteria": "cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*",
                                    "versionStartIncluding": "5.15.81"
                                },
                                {
                                    "vulnerable": true,
                                    "criteria": "cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*",
                                    "versionStartIncluding": "6.0.11"
                                }
                            ]
                        }
                    ]
                }
            ],
            "references": [
                {
                    "url": "https://git.kernel.org/stable/c/ec24e62a1dd3540ee696314422040180040c1e4a"
                },
                {
                    "url": "https://git.kernel.org/stable/c/d362b21fefcef7eda8f1cd78a5925735d2b3287c"
                },
                {
                    "url": "https://git.kernel.org/stable/c/e9b28bc65fd3a56755ba503258024608292b4ab1"
                },
                {
                    "url": "https://git.kernel.org/stable/c/a2620f8932fa9fdabc3d78ed6efb004ca409019f"
                }
            ],
            "title": "KVM: SVM: Forcibly leave SMM mode on SHUTDOWN interception",
            "x_generator": {
                "engine": "bippy-1.2.0"
            }
        }
    }
}