FlawAtlas
Search the atlas
UBUNTU-CVE-2017-1000405 High

UBUNTU-CVE-2017-1000405

The Linux Kernel versions 2.6.38 through 4.14 have a problematic use of pmd_mkdirty() in the touch_pmd() function inside the THP implementation. touch_pmd() can be reached by get_user_pages(). In such case, the pmd will become dirty. This scenario breaks the new can_follow_write_pmd()'s logic - pmd can become dirty without going through a COW cycle. This bug is not as severe as the original "Dirty cow" because an ext4 file (or any other regular file) cannot be mapped using THP. Nevertheless, it does allow us to overwrite read-only huge pages. For example, the zero huge page and sealed shmem files can be overwritten (since their mapping can be populated using THP). Note that after the first write page-fault to the zero page, it will be replaced with a new fresh (and zeroed) thp.

Exploit probability Not scored
Published November 30, 2017
Required by Not available
Last source change April 22, 2026

02 / AFFECTED SOFTWARE

Affected packages

Ubuntu:14.04:LTS linux

123 explicit affected versions

Ubuntu:14.04:LTS linux-aws

2 explicit affected versions

Ubuntu:14.04:LTS linux-lts-xenial

42 explicit affected versions

Ubuntu:16.04:LTS linux

64 explicit affected versions

Ubuntu:16.04:LTS linux-aws

23 explicit affected versions

Ubuntu:16.04:LTS linux-azure

5 explicit affected versions

Ubuntu:16.04:LTS linux-gcp

5 explicit affected versions

Ubuntu:16.04:LTS linux-hwe

26 explicit affected versions

Ubuntu:16.04:LTS linux-kvm

5 explicit affected versions

Ubuntu:16.04:LTS linux-oem

1 explicit affected versions

Ubuntu:16.04:LTS linux-raspi2

40 explicit affected versions

Ubuntu:16.04:LTS linux-snapdragon

37 explicit affected versions

Ubuntu:18.04:LTS linux-hwe

43 explicit affected versions

Ubuntu:18.04:LTS linux-hwe-edge

10 explicit affected versions

Ubuntu:20.04:LTS linux-azure-fde

26 explicit affected versions

Ubuntu:20.04:LTS linux-gke

51 explicit affected versions

Ubuntu:20.04:LTS linux-raspi2

6 explicit affected versions

Ubuntu:20.04:LTS linux-riscv

12 explicit affected versions

Ubuntu:22.04:LTS linux-intel-iot-realtime

1 explicit affected versions

Ubuntu:22.04:LTS linux-realtime

1 explicit affected versions

Ubuntu:22.04:LTS linux-riscv

23 explicit affected versions

Ubuntu:24.04:LTS linux-raspi-realtime

1 explicit affected versions

Ubuntu:Pro:FIPS:16.04:LTS linux-fips

1 explicit affected versions

03 / CONNECTIONS

Connected vulnerabilities

related USN-3507-1
related USN-3508-1
related USN-3510-2

04 / EVIDENCE

Source records

Open Source Vulnerabilities UBUNTU-CVE-2017-1000405

The Linux Kernel versions 2.6.38 through 4.14 have a problematic use of pmd_mkdirty() in the touch_pmd() function inside the THP implementation. touch_pmd() can be reached by get_user_pages(). In such case, the pmd will become dirty. This scenario breaks the new can_follow_write_pmd()'s logic - pmd can become dirty without going through a COW cycle. This bug is not as severe as the original "Dirty cow" because an ext4 file (or any other regular file) cannot be mapped using THP. Nevertheless, it does allow us to overwrite read-only huge pages. For example, the zero huge page and sealed shmem files can be overwritten (since their mapping can be populated using THP). Note that after the first write page-fault to the zero page, it will be replaced with a new fresh (and zeroed) thp.

View original source

05 / REFERENCES

Further evidence