CVE-2020-10757
Linux Kernel vulnerability analysis and mitigation

Overview

A flaw was found in the Linux Kernel in versions after 4.5-rc1 in the way mremap handled DAX Huge Pages. The vulnerability was discovered by Fan Yang and assigned CVE-2020-10757. The issue was introduced in commit 5c7fb56 ("mm, dax: dax-pmd vs thp-pmd vs hugetlbfs-pmd") and fixed in June 2020 (Kernel Git).

Technical details

The vulnerability exists because the mremap implementation did not properly handle DAX (Direct Access) Huge Pages. The condition to handle a huge PMD (Page Middle Directory) in movepagetables only checked for swappmd or pmdtrans_huge, but did not account for DAX mapped files which are mapped as huge pages but are not transparent huge pages. This caused the huge PMD not to be split, resulting in the physical page being incorrectly treated as a page table when it was actually a 2MB data page (OpenWall).

Impact

This vulnerability allows a local attacker with access to a DAX enabled storage to escalate their privileges on the system. The attacker could effectively control PTEs (Page Table Entries) and create physical to virtual mappings at will (NVD).

Mitigation and workarounds

The vulnerability was patched in Linux kernel version 5.6.16 and backported to various stable kernel versions. The fix involves modifying the condition in movepagetables to also check for pmddevmap when handling huge pages. For systems that cannot be immediately patched, the recommended workaround is to avoid using DAX enabled storage ([Red Hat Bugzilla](https://bugzilla.redhat.com/showbug.cgi?id=1842525)).

Additional resources


SourceThis report was generated using AI

Free Vulnerability Assessment

Benchmark your Cloud Security Posture

Evaluate your cloud security practices across 9 security domains to benchmark your risk level and identify gaps in your defenses.

Request assessment

Get a personalized demo

Ready to see Wiz in action?

"Best User Experience I have ever seen, provides full visibility to cloud workloads."
David EstlickCISO
"Wiz provides a single pane of glass to see what is going on in our cloud environments."
Adam FletcherChief Security Officer
"We know that if Wiz identifies something as critical, it actually is."
Greg PoniatowskiHead of Threat and Vulnerability Management