KVM: arm64: Fix uninitialized memcache pointer in user_mem_abort()
Linux
Affected versions
| Product | Affected | Fixed in |
|---|---|---|
| Linux Linux |
| No fix yet |
| Linux Linux |
|
|
Linux
| Product | Affected | Fixed in |
|---|---|---|
| Linux Linux |
| No fix yet |
| Linux Linux |
|
|
In the Linux kernel, the following vulnerability has been resolved:
KVM: arm64: Fix uninitialized memcache pointer in user_mem_abort()
Commit fce886a60207 ("KVM: arm64: Plumb the pKVM MMU in KVM") made the initialization of the local memcache variable in user_mem_abort() conditional, leaving a codepath where it is used uninitialized via kvm_pgtable_stage2_map().
This can fail on any path that requires a stage-2 allocation without transition via a permission fault or dirty logging.
Fix this by making sure that memcache is always valid.
From the CVE record · Linux
In the Linux kernel’s KVM arm64 code, user_mem_abort() can pass an uninitialized memcache pointer to kvm_pgtable_stage2_map(). This can fail when a path requires a stage-2 allocation without a permission-fault or dirty-logging transition. The input does not specify an attacker’s required access or whether user interaction is needed.
Engineers running Linux kernels with KVM arm64 should check whether their kernel includes the affected code; affected versions are not specified.