{"id":"CVE-2025-37996","state":"PUBLISHED","title":"KVM: arm64: Fix uninitialized memcache pointer in user_mem_abort()","description":"In the Linux kernel, the following vulnerability has been resolved:\n\nKVM: arm64: Fix uninitialized memcache pointer in user_mem_abort()\n\nCommit fce886a60207 (\"KVM: arm64: Plumb the pKVM MMU in KVM\") made the\ninitialization of the local memcache variable in user_mem_abort()\nconditional, leaving a codepath where it is used uninitialized via\nkvm_pgtable_stage2_map().\n\nThis can fail on any path that requires a stage-2 allocation\nwithout transition via a permission fault or dirty logging.\n\nFix this by making sure that memcache is always valid.","publishedAt":"2025-05-29T13:15:54.956Z","updatedAt":"2026-08-05T11:58:48.143Z","severity":{"score":8.8,"label":"High","version":"3.1","vector":"CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:C/C:H/I:H/A:H","source":"Linux"},"assigner":"Linux","products":["Linux Linux"],"affected":[{"vendor":"Linux","product":"Linux","defaultStatus":"unaffected","versions":[{"version":"fce886a6020734d6253c2c5a3bc285e385cc5496","status":"affected","lessThan":"a26d50f8a4a5049e956984797b5d0dedea4bbb18","versionType":"git"},{"version":"fce886a6020734d6253c2c5a3bc285e385cc5496","status":"affected","lessThan":"157dbc4a321f5bb6f8b6c724d12ba720a90f1a7c","versionType":"git"}],"repo":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","programFiles":["arch/arm64/kvm/mmu.c"]},{"vendor":"Linux","product":"Linux","defaultStatus":"affected","versions":[{"version":"6.14","status":"affected"},{"version":"0","status":"unaffected","lessThan":"6.14","versionType":"semver"},{"version":"6.14.7","status":"unaffected","lessThanOrEqual":"6.14.*","versionType":"semver"},{"version":"6.15","status":"unaffected","lessThanOrEqual":"*","versionType":"original_commit_for_fix"}],"repo":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","programFiles":["arch/arm64/kvm/mmu.c"]}],"references":["https://git.kernel.org/stable/c/a26d50f8a4a5049e956984797b5d0dedea4bbb18","https://git.kernel.org/stable/c/157dbc4a321f5bb6f8b6c724d12ba720a90f1a7c"],"weaknesses":[],"ingestedAt":"2026-10-29T20:09:03.054Z","source":{"repository":"CVEProject/cvelistV5","path":"cves/2025/37xxx/CVE-2025-37996.json","commit":"556c9d3a8cd17e218bb8e452ba7cd619a384ff47"},"raw":{"dataType":"CVE_RECORD","dataVersion":"5.2","cveMetadata":{"cveId":"CVE-2025-37996","state":"PUBLISHED","datePublished":"2025-05-29T13:15:54.956Z","dateUpdated":"2026-08-05T11:58:48.143Z","assignerShortName":"Linux","assignerOrgId":"416baaa9-dc9f-4396-8d5f-8c081fb06d67","dateReserved":"2025-04-16T04:51:23.976Z"},"containers":{"cna":{"title":"KVM: arm64: Fix uninitialized memcache pointer in user_mem_abort()","descriptions":[{"lang":"en","value":"In the Linux kernel, the following vulnerability has been resolved:\n\nKVM: arm64: Fix uninitialized memcache pointer in user_mem_abort()\n\nCommit fce886a60207 (\"KVM: arm64: Plumb the pKVM MMU in KVM\") made the\ninitialization of the local memcache variable in user_mem_abort()\nconditional, leaving a codepath where it is used uninitialized via\nkvm_pgtable_stage2_map().\n\nThis can fail on any path that requires a stage-2 allocation\nwithout transition via a permission fault or dirty logging.\n\nFix this by making sure that memcache is always valid."}],"affected":[{"vendor":"Linux","product":"Linux","defaultStatus":"unaffected","versions":[{"version":"fce886a6020734d6253c2c5a3bc285e385cc5496","status":"affected","lessThan":"a26d50f8a4a5049e956984797b5d0dedea4bbb18","versionType":"git"},{"version":"fce886a6020734d6253c2c5a3bc285e385cc5496","status":"affected","lessThan":"157dbc4a321f5bb6f8b6c724d12ba720a90f1a7c","versionType":"git"}],"repo":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","programFiles":["arch/arm64/kvm/mmu.c"]},{"vendor":"Linux","product":"Linux","defaultStatus":"affected","versions":[{"version":"6.14","status":"affected"},{"version":"0","status":"unaffected","lessThan":"6.14","versionType":"semver"},{"version":"6.14.7","status":"unaffected","lessThanOrEqual":"6.14.*","versionType":"semver"},{"version":"6.15","status":"unaffected","lessThanOrEqual":"*","versionType":"original_commit_for_fix"}],"repo":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","programFiles":["arch/arm64/kvm/mmu.c"]}],"references":[{"url":"https://git.kernel.org/stable/c/a26d50f8a4a5049e956984797b5d0dedea4bbb18"},{"url":"https://git.kernel.org/stable/c/157dbc4a321f5bb6f8b6c724d12ba720a90f1a7c"}],"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 vulnerable code is the host kernel's stage-2 fault handler, reached through guest execution under KVM_RUN (or directly by a local user with /dev/kvm who builds their own VM); there is no network-facing path.\nAC:L - No race or unpredictable precondition is involved — an attacker controlling a guest can deterministically arrange a huge-block stage-2 mapping and then take a non-write permission fault (instruction fetch, or an NV shadow-S2 granule mismatch) so that `memcache` is consumed uninitialized on every attempt.\nPR:L - The attacker only needs code execution inside a guest VM, or unprivileged access to /dev/kvm on the host (commonly group- or world-accessible on Android, desktops and libvirt hosts); no host root is required.\nUI:N - The fault is raised by the guest's own memory access during normal vCPU execution, with no action needed from the host operator or any other user.\nS:C - The bug lets a guest corrupt host-kernel memory through the stage-2 page-table allocator, crossing from the VM's security authority into the hypervisor host — a guest-to-host boundary violation.\nC:H - `kvm_mmu_memory_cache_alloc()` performs `mc->objects[--mc->nobjs]` through the garbage pointer, an attacker-influenceable arbitrary read whose result is then mapped into the guest's stage-2 tables, exposing host memory contents to the guest.\nI:H - The uninitialized pointer yields wild writes (`--mc->nobjs`, and under pKVM `swap(mapping, cache->mapping)` followed by `mapping->gfn/pfn` stores) and causes arbitrary host memory to be installed as a guest stage-2 page table with matching `get_page`/`put_page` refcount manipulation — a host memory-corruption and control-flow-hijack primitive.\nA:H - In the ordinary case the wild dereference (or the `BUG_ON(!p)` in `kvm_mmu_memory_cache_alloc()`) oopses in the vCPU thread while holding the KVM fault lock, panicking the host kernel and taking down every VM on the machine."}]}],"providerMetadata":{"shortName":"Linux","orgId":"416baaa9-dc9f-4396-8d5f-8c081fb06d67","dateUpdated":"2026-08-05T11:58:48.143Z"},"cpeApplicability":[{"nodes":[{"operator":"OR","negate":false,"cpeMatch":[{"vulnerable":true,"criteria":"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*","versionStartIncluding":"6.14","versionEndExcluding":"6.14.7"},{"vulnerable":true,"criteria":"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*","versionStartIncluding":"6.14","versionEndExcluding":"6.15"}]}]}],"x_generator":{"engine":"bippy-1.2.0"}}}}}