CVE-2017-1000405
Description
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.
Weakness
- CWE-362: Concurrent Execution using Shared Resource with Improper Synchronization
Timeline
- 2017-11-30Published by the CNA22:00 UTC
- 2017-11-30First Exploit-DB entry (EDB-ID 43199)same day
Exploit and advisory records
| Exploit-DB | Type | Platform | Published | EDB-verified |
|---|---|---|---|---|
| EDB-ID 44305 | dos | linux | 2017-12-11 | no |
| EDB-ID 43199 | dos | linux | 2017-11-30 | no |
Affected products
Products listed as vulnerable. Upgrade to the version under "Fixed in", or a later one.
| Product | Vulnerable versions | Fixed in |
|---|---|---|
| linux linux_kernel | from 3.10.106 before 3.11fixed in 3.11from 3.12.73 before 3.13fixed in 3.13from 3.16.42 before 3.16.52fixed in 3.16.52from 3.18.55 before 3.18.86fixed in 3.18.86from 3.2.87 before 3.3fixed in 3.3(+4 more) | 3.113.133.16.523.18.863.3 |
References
- https://access.redhat.com/errata/RHSA-2018:0180
- https://medium.com/bindecy/huge-dirty-cow-cve-2017-1000405-110eca132de0
- https://www.exploit-db.com/exploits/43199/
- http://www.securityfocus.com/bid/102032
- http://www.securitytracker.com/id/1040020
- https://source.android.com/security/bulletin/pixel/2018-02-01
Get more CVE data from the API.
curl 'https://api.contrastcyber.com/cve_lookup/CVE-2017-1000405'curl 'https://api.contrastcyber.com/cve_risk_score/CVE-2017-1000405'curl 'https://api.contrastcyber.com/cve_exploit/CVE-2017-1000405'curl 'https://api.contrastcyber.com/cve_products/CVE-2017-1000405'
Sources
- Vulnerability data from the National Vulnerability Database (NIST) and the CVE Program. CVE records: Copyright © 1999-2026, The MITRE Corporation, used under the CVE Program Terms of Use. CVE® is a registered trademark of The MITRE Corporation.
- CWE definitions: Copyright © 2006-2026, The MITRE Corporation, used under the CWE Terms of Use. CWE is a trademark of The MITRE Corporation.
- OWASP Top 10 categories by the OWASP Foundation (CC BY 3.0).
- EPSS scores by FIRST.org EPSS, used with attribution.
- KEV catalog and SSVC decisions by CISA.
- Advisory data from the GitHub Advisory Database through OSV.dev (CC BY 4.0).
- Exploit metadata from the Exploit Database (GPL-2.0-only, metadata only).
- Nuclei template names from nuclei-templates (MIT).