CVE-2025-21696 Details
Description
In the Linux kernel, the following vulnerability has been resolved: mm: clear uffd-wp PTE/PMD state on mremap() When mremap()ing a memory region previously registered with userfaultfd as write-protected but without UFFD_FEATURE_EVENT_REMAP, an inconsistency in flag clearing leads to a mismatch between the vma flags (which have uffd-wp cleared) and the pte/pmd flags (which do not have uffd-wp cleared). This mismatch causes a subsequent mprotect(PROT_WRITE) to trigger a warning in page_table_check_pte_flags() due to setting the pte to writable while uffd-wp is still set. Fix this by always explicitly clearing the uffd-wp pte/pmd flags on any such mremap() so that the values are consistent with the existing clearing of VM_UFFD_WP. Be careful to clear the logical flag regardless of its physical form; a PTE bit, a swap PTE bit, or a PTE marker. Cover PTE, huge PMD and hugetlb paths.
A vulnerability in the Linux kernel's memory management can lead to inconsistencies when remapping memory regions that are registered with userfaultfd as write-protected. This issue arises because the flags indicating the write-protected state are not properly synchronized between the virtual memory area (VMA) and the page table entries (PTE/PMD). As a result, a subsequent attempt to change the protection to writable can trigger a warning, creating potential disruptions in memory management.
The vulnerability has been addressed by ensuring that the userfaultfd write-protect flags in the page table entries are consistently cleared during the memory remapping process, aligning them with the existing virtual memory area flags.
Metrics
CVSS 4.0 Severity and Vector Strings:
No CVSS 4.0 data is available for this CVE.
CVSS 3.x Severity and Vector Strings:
No data available for CVSS Version 2.0 on this CVE.
CISA-ADP
Assessed Oct 1, 2025References to Advisories, Solutions, and Tools
By selecting these links, you will be leaving this site. These are references gathered from the official CVE record and are not endorsed by Volerion.
| URL | Source(s) | Tag(s) |
|---|---|---|
| https://git.kernel.org/stable/c/0cef0bb836e3cfe00f08f9606c72abd72fe78ca3 | kernel.org | Patch |
| https://git.kernel.org/stable/c/310ac886d68de661c3a334198d8604b722d7fdf8 | kernel.org | Patch |
Weakness Enumeration
| CWE-ID | CWE Name | Source |
|---|---|---|
| NVD-CWE-noinfo | Insufficient Information to Classify Weakness | [email protected] |
Affected Products
| Product | Versions |
|---|---|
| linux linux kernel | >= 5.7, < 6.12.11 6.13 rc1 6.13 rc2 6.13 rc3 6.13 rc4 6.13 rc5 6.13 rc6 6.13 rc7 |
CPE
Remediation
| |
Change History
5 change records found show changes
| Date | Action | Recorded By |
|---|---|---|
| Jun 17, 2026 | CVE Modified | kernel.org |
| Jun 17, 2026 | CVE Modified | CISA-ADP |
| Oct 1, 2025 | CVE Modified | CISA-ADP |
| Feb 14, 2025 | Initial Analysis | [email protected] |
| Feb 12, 2025 | New CVE Received | kernel.org |