PT-2024-10100 · Linux+4 · Linux Kernel+4

Mortem

·

Published

2024-10-22

·

Updated

2026-02-21

·

CVE-2024-50066

CVSS v3.1

7.0

High

VectorAV:L/AC:H/PR:L/UI:N/S:U/C:H/I:H/A:H
Name of the Vulnerable Software and Affected Versions Linux kernel versions prior to 6.6.58
Description The issue is related to a race condition in the move page tables() function, specifically between move normal pmd() and retract page tables() in the THP code. This can lead to the creation of bogus PMD entries, potentially allowing for user-to-kernel privilege escalation on certain architectures, such as x86. The vulnerability can be exploited by creating shmem/file THP mappings and racing the move normal pmd() and retract page tables() functions.
The move page tables() function looks at the type of the PMD entry and the specified address range to determine how to move the next chunk of page table entries. The mmap lock is held in write mode, but no rmap locks are held yet. For PMD entries that point to page tables and are fully covered by the source address range, move pgt entry(NORMAL PMD, ...) is called, which first takes rmap locks, then does move normal pmd().
The move normal pmd() function takes the necessary page table locks at source and destination, then moves an entire page table from the source to the destination. The problem is that the rmap locks, which protect against concurrent page table removal by retract page tables() in the THP code, are only taken after the PMD entry has been read and it has been decided how to move it.
Recommendations To resolve the issue, upgrade the Linux kernel to version 6.6.58 or later. As a temporary workaround, consider restricting the use of shmem/file THP mappings to minimize the risk of exploitation. Avoid using the mremap() function with move page tables() until the issue is resolved.

Exploit

Fix

Race Condition

Found an issue in the description? Have something to add? Feel free to write us 👾

Weakness Enumeration

Related Identifiers

ALSA-2025_12746
ALSA-2025_12752
ALSA-2025_12753
ALSA-2025_16880
ALT-PU-2024-17211
ALT-PU-2025-12647
AZL-52169
BDU:2025-00297
CVE-2024-50066
MGASA-2024-0344
MGASA-2024-0345
OESA-2024-2367
OPENSUSE-SU-2024:14500-1
OPENSUSE-SU-2025:14705-1
USN-7276-1
USN-7277-1
USN-7310-1
USN-7383-1
USN-7383-2
USN-7384-1
USN-7384-2
USN-7385-1
USN-7386-1
USN-7403-1
USN-7451-1
USN-7468-1
USN-7523-1
USN-7524-1

Affected Products

Alt Linux
Linuxmint
Linux Kernel
Red Os
Ubuntu