CVE-2017-1000405
Linux Kernel - 'The Huge Dirty Cow' Overwriting The Huge Zero Page
Severity Score
Exploit Likelihood
Affected Versions
Public Exploits
4Exploited in Wild
-Decision
Descriptions
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.
El kernel de Linux desde la versión 2.6.38 hasta la 4.14 presenta un uso problemático de pmd_mkdirty() en la función touch_pmd() dentro de la implementación THP. Se puede llegar a touch_pmd() con get_user_pages(). En ese caso, el pmd se ensuciaría. Este escenario rompe la nueva lógica de can_follow_write_pmd(). pmd puede contaminarse sin pasar por un ciclo COW. Este fallo no es tan severo como el error original "Dirty COW" porque un archivo ext4 (o cualquier otro archivo normal) no puede ser mapeado usando THP. Sin embargo, permite sobrescribir huge pages de solo lectura. Por ejemplo, los archivos shmem sellados y huge pages con ceros pueden sobrescribirse (ya que se pueden mapear con THP). Tenga en cuenta que después del primer error de escritura de página en la página con cero, se reemplazará por un nuevo thp (y con ceros).
A flaw was found in the patches used to fix the 'dirtycow' vulnerability (CVE-2016-5195). An attacker, able to run local code, can exploit a race condition in transparent huge pages to modify usually read-only huge pages.
CVSS Scores
SSVC
- Decision:-
Timeline
- 2017-11-29 CVE Reserved
- 2017-11-30 CVE Published
- 2017-12-11 First Exploit
- 2024-08-05 CVE Updated
- 2024-12-17 EPSS Updated
- ---------- Exploited in Wild
- ---------- KEV Due Date
CWE
- CWE-362: Concurrent Execution using Shared Resource with Improper Synchronization ('Race Condition')
CAPEC
References (10)
URL | Tag | Source |
---|---|---|
http://www.securityfocus.com/bid/102032 | Third Party Advisory | |
http://www.securitytracker.com/id/1040020 | Third Party Advisory | |
https://source.android.com/security/bulletin/pixel/2018-02-01 | Third Party Advisory |
URL | Date | SRC |
---|---|---|
https://www.exploit-db.com/exploits/44305 | 2017-12-11 | |
https://www.exploit-db.com/exploits/43199 | 2024-08-05 | |
https://github.com/bindecy/HugeDirtyCowPOC | 2024-08-12 | |
https://medium.com/bindecy/huge-dirty-cow-cve-2017-1000405-110eca132de0 | 2024-08-05 |
URL | Date | SRC |
---|
URL | Date | SRC |
---|---|---|
https://access.redhat.com/errata/RHSA-2018:0180 | 2023-06-26 | |
https://access.redhat.com/security/cve/CVE-2017-1000405 | 2018-01-25 | |
https://bugzilla.redhat.com/show_bug.cgi?id=1516514 | 2018-01-25 |
Affected Vendors, Products, and Versions
Vendor | Product | Version | Other | Status | ||||||
---|---|---|---|---|---|---|---|---|---|---|
Vendor | Product | Version | Other | Status | <-- --> | Vendor | Product | Version | Other | Status |
Linux Search vendor "Linux" | Linux Kernel Search vendor "Linux" for product "Linux Kernel" | >= 3.2.87 < 3.3 Search vendor "Linux" for product "Linux Kernel" and version " >= 3.2.87 < 3.3" | - |
Affected
| ||||||
Linux Search vendor "Linux" | Linux Kernel Search vendor "Linux" for product "Linux Kernel" | >= 3.10.106 < 3.11 Search vendor "Linux" for product "Linux Kernel" and version " >= 3.10.106 < 3.11" | - |
Affected
| ||||||
Linux Search vendor "Linux" | Linux Kernel Search vendor "Linux" for product "Linux Kernel" | >= 3.12.73 < 3.13 Search vendor "Linux" for product "Linux Kernel" and version " >= 3.12.73 < 3.13" | - |
Affected
| ||||||
Linux Search vendor "Linux" | Linux Kernel Search vendor "Linux" for product "Linux Kernel" | >= 3.16.42 < 3.16.52 Search vendor "Linux" for product "Linux Kernel" and version " >= 3.16.42 < 3.16.52" | - |
Affected
| ||||||
Linux Search vendor "Linux" | Linux Kernel Search vendor "Linux" for product "Linux Kernel" | >= 3.18.55 < 3.18.86 Search vendor "Linux" for product "Linux Kernel" and version " >= 3.18.55 < 3.18.86" | - |
Affected
| ||||||
Linux Search vendor "Linux" | Linux Kernel Search vendor "Linux" for product "Linux Kernel" | >= 4.1.41 < 4.1.48 Search vendor "Linux" for product "Linux Kernel" and version " >= 4.1.41 < 4.1.48" | - |
Affected
| ||||||
Linux Search vendor "Linux" | Linux Kernel Search vendor "Linux" for product "Linux Kernel" | >= 4.4.70 < 4.4.104 Search vendor "Linux" for product "Linux Kernel" and version " >= 4.4.70 < 4.4.104" | - |
Affected
| ||||||
Linux Search vendor "Linux" | Linux Kernel Search vendor "Linux" for product "Linux Kernel" | >= 4.9.7 < 4.9.67 Search vendor "Linux" for product "Linux Kernel" and version " >= 4.9.7 < 4.9.67" | - |
Affected
| ||||||
Linux Search vendor "Linux" | Linux Kernel Search vendor "Linux" for product "Linux Kernel" | >= 4.10 < 4.14.4 Search vendor "Linux" for product "Linux Kernel" and version " >= 4.10 < 4.14.4" | - |
Affected
|