ARM: 9485/1: mm: acquire mmap write lock around show_pte() for user faults
- Published
- Last modified
- Where the record stands: published, rejected by its publisher, or superseded by another id.What do these mean? →
- published
- Whether CISA lists it in its Known Exploited Vulnerabilities catalog: proof that attackers are using it.What do these mean? →
- Not listed in CISA KEV
- Fix
- Fixed in 5.10.270, 5.15.221, 6.1.188, 6.6.157, 6.12.110, and 2 more
- Whether working attack code is public (Exploit-DB, Metasploit, Nuclei or GitHub). Public code makes attacks easier.What do these mean? →
- None on Exploit-DB, Metasploit or GitHub
Summary
In the Linux kernel, the following vulnerability has been resolved: ARM: 9485/1: mm: acquire mmap write lock around show_pte() for user faults When CONFIG_DEBUG_USER=y, and cmdline "user_debug=31" is set, a user fault may trigger show_pte() without any lock. If another thread in the same process concurrently calls munmap(), the page table pages may be freed while show_pte() is still traversing them, causing a use-after-free in show_pte(). If CONFIG_ARM_LPAE=y, this may cause a kernel panic if the pages table of PMD are freed when show_pte() is running. Acquire mmap_write_lock() around show_pte() for user faults to fix the contention. For user faults, additionally restrict that show_pte() is called only when the addr is a user-space address (addr < TASK_SIZE). This is because the lock of tsk->mm only protects the virtual memory of user address space, furthermore, dumping the page tables of a kernel-space address for user faults is unnecessary and may have security implications. Keep everything unchanged for kernel faults, because the kernel is already in the "oops" state, acquiring a lock may risk a deadlock.
Timeline
- CVE published
- Record last updated
Affected versions
- Linux Linux
From 6d021b724481fbb908eb29384898deb9f00dfe70 · fixed in ab14f07952adfe735d86a53518f8cd576dfd5892; From 6d021b724481fbb908eb29384898deb9f00dfe70 · fixed in 07e4d5380f2a844ab7a1b440dde350caf561cbb0; From 6d021b724481fbb908eb29384898deb9f00dfe70 · fixed in 2a14d7797a49a47bccd1a9327fd69da838dcb0dd; From 6d021b724481fbb908eb29384898deb9f00dfe70 · fixed in 63e3c958a602d0896a101a897c2361878c266ca7; From 6d021b724481fbb908eb29384898deb9f00dfe70 · fixed in 59bbf86d0ff9373bfa033ca123c1e924f09f1eba; From 6d021b724481fbb908eb29384898deb9f00dfe70 · fixed in c71f9a56520b419e55d173052629f2324deb5549; From 6d021b724481fbb908eb29384898deb9f00dfe70 · fixed in 720408d98d9fb3c91a12090436734c8c61f04545; From 6d021b724481fbb908eb29384898deb9f00dfe70 · fixed in 1039bffd6ae9c75b42b7d148d6c1106134107b66
- Linux Linux
4.0
- KernelLinux
From 4.0.0 · fixed in 5.10.270; From 5.11.0 · fixed in 5.15.221; From 5.16.0 · fixed in 6.1.188; From 6.2.0 · fixed in 6.6.157; From 6.7.0 · fixed in 6.12.110; From 6.13.0 · fixed in 6.18.52; From 6.19.0 · fixed in 7.2.6
References 8
git.kernel.org
- stable/c/ab14f07952adfe735d86a53518f8cd576dfd5892
- stable/c/07e4d5380f2a844ab7a1b440dde350caf561cbb0
- stable/c/2a14d7797a49a47bccd1a9327fd69da838dcb0dd
- stable/c/63e3c958a602d0896a101a897c2361878c266ca7
- stable/c/59bbf86d0ff9373bfa033ca123c1e924f09f1eba
- stable/c/c71f9a56520b419e55d173052629f2324deb5549
- stable/c/720408d98d9fb3c91a12090436734c8c61f04545
- stable/c/1039bffd6ae9c75b42b7d148d6c1106134107b66