Linux Kernel Memory Management Vulnerability in mprotect Handling

Vulnerability

A vulnerability in the Linux kernel's memory management subsystem has been identified, specifically in the handling of the 'mprotect' system call. This issue arises from a recent change that added a type check for swap entries, which inadvertently introduced a kernel bug. The vulnerability can lead to a kernel crash by triggering a 'BUG' condition when the 'pfn_swap_entry_to_page' function is called with a genuine swap entry. The problem occurs because the function is not properly validating the type of the swap entry before reference, particularly in cases of write migration entries where the page is actively used.

Impact

Exploitation of this vulnerability causes a kernel panic, leading to a system crash.

Reproduction

The vulnerability can be reproduced by invoking the 'mprotect' system call with a genuine swap entry that is a write migration entry. This can be done by creating a scenario where the swap entry is active and then applying the 'mprotect' call, which will trigger the improper handling and cause a kernel crash.

Added: Jun 18, 2025, 8:51 PM
Updated: Jun 18, 2025, 8:51 PM

Vulnerability Rating

Custom Algorithm
spread
9.0
impact
2.5
exploitability
3.9
remediation
0.0
relevance
0.2
threat
4.8
urgency
2.9
incentive
1.7

Our algorithm analyzes dozens of metrics to generate these 8 key vulnerability categories, which are then combined to calculate the overall risk score.