Vulnerability record · CVE-2020-13671 · published 20 November 2020
CVE-2020-13671: Drupal core filename sanitization flaw allows uploaded files to execute as PHP
DDrupal · Drupal
Drupal core fails to properly sanitize certain filenames on uploaded files, so files can be interpreted with the wrong extension and served as the wrong MIME type or executed as PHP under certain hosting configurations. It affects Drupal Core 9.0 before 9.0.8, 8.9 before 8.9.9, 8.8 before 8.8.11, and 7 before 7.74. Because it enables code execution on the server, it is a serious risk for any unpatched Drupal site that permits file uploads.
Description
Drupal core does not properly sanitize certain filenames on uploaded files, which can lead to files being interpreted as the incorrect extension and served as the wrong MIME type or executed as PHP for certain hosting configurations. This issue affects: Drupal Drupal Core 9.0 versions prior to 9.0.8, 8.9 versions prior to 8.9.9, 8.8 versions prior to 8.8.11, and 7 versions prior to 7.74.
CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H
Automated analysis
high priorityThe flaw allows remote code execution via file upload, is listed in CISA KEV as exploited, and carries a high EPSS score, though it requires a low-privileged authenticated account.
What it is
Drupal core fails to properly sanitize certain filenames on uploaded files, so files can be interpreted with the wrong extension and served as the wrong MIME type or executed as PHP under certain hosting configurations. It affects Drupal Core 9.0 before 9.0.8, 8.9 before 8.9.9, 8.8 before 8.8.11, and 7 before 7.74. Because it enables code execution on the server, it is a serious risk for any unpatched Drupal site that permits file uploads.
Impact
An attacker with the ability to upload files can place a file that the server executes as PHP, gaining code execution in the web server context. That can lead to full compromise of the Drupal site and its data.
Attack surface
The flaw is reached over the network through Drupal's file upload functionality, as reflected by the CVSS vector AV:N/PR:L/UI:N. It requires a low-privileged authenticated account able to upload files; no user interaction is needed.
Exploitation
CVE-2020-13671 is listed in CISA KEV with a due date of 2022-07-18, indicating known exploitation, and EPSS shows a 30-day probability of 0.3535 (98.4th percentile). No ransomware campaign use is documented.
What to do
- Upgrade Drupal core to 9.0.8, 8.9.9, 8.8.11, or 7.74 (or later) as directed by the vendor advisory sa-core-2020-012.
- Apply the corresponding Fedora package updates referenced in the Fedora package-announce mailing lists.
- Restrict file upload permissions to only trusted roles and review which roles can upload files.
- Harden the web server so uploaded files cannot be executed as PHP (for example, disable script execution in upload directories).
Detection
- Monitor upload directories for newly written files with executable extensions or mismatched MIME types.
- Alert on web server or PHP logs showing execution of files from user upload paths.
- Audit Drupal file entities and recent uploads for suspicious filenames or extensions.
- Track Drupal core versions across the estate to find hosts still below the fixed releases.
This assessment is produced automatically and is not human-reviewed. Verify against the vendor advisory before acting on it.
Exploitation in the wild
CISA added CVE-2020-13671 to the Known Exploited Vulnerabilities catalog on 18 January 2022 as "Drupal core Un-restricted Upload of File". Required action: Apply updates per vendor instructions. Federal deadline 18 July 2022.
Affected products
2 vulnerable configurations from NVD's CPE data, grouped by vendor and product.
References
| Link | Tags |
|---|---|
| https://lists.fedoraproject.org/archives/list/package-announce%40lists.fedoraproject.org/message/5KSFM672XW3X6BR7TVKRD63 | Mailing ListRelease Notes |
| https://lists.fedoraproject.org/archives/list/package-announce%40lists.fedoraproject.org/message/KWM4CTMEGAC4I2CHYNJVSRO | Mailing ListRelease Notes |
| https://www.drupal.org/sa-core-2020-012 | Vendor Advisory |
| https://lists.fedoraproject.org/archives/list/package-announce%40lists.fedoraproject.org/message/5KSFM672XW3X6BR7TVKRD63 | Mailing ListRelease Notes |
| https://lists.fedoraproject.org/archives/list/package-announce%40lists.fedoraproject.org/message/KWM4CTMEGAC4I2CHYNJVSRO | Mailing ListRelease Notes |
| https://www.drupal.org/sa-core-2020-012 | Vendor Advisory |
| https://www.cisa.gov/known-exploited-vulnerabilities-catalog?field_cve=CVE-2020-13671 | US Government Resource |
Track CVE-2020-13671 inside VULONE
Watch it alongside the ransomware crews, C2 infrastructure and forum chatter that reference it, query it through the API and pull it into your SIEM over TAXII.
Related vulnerabilities
Same products first, then exploited flaws of the same weakness class.
Source: NIST National Vulnerability Database (record CVE-2020-13671), CISA KEV, FIRST EPSS (scores of 2026-09-26). This page is refreshed as NVD updates the record.