CVE-2017-15715 in apache http server
LogPulse has a published detection rule for this CVE: it raises a notable when someone tries to exploit it.
What the vulnerability is
In Apache httpd 2.4.0 to 2.4.29, the expression specified in <FilesMatch> could match '$' to a newline character in a malicious filename, rather than matching only the end of the filename. This could be exploited in environments where uploads of some files are are externally blocked, but only by matching the trailing portion of the filename.
Affected software: apache http server, netapp santricity cloud connector, netapp storage automation store, netapp storagegrid, debian linux, canonical ubuntu linux, netapp clustered data ontap, redhat enterprise linux
Scores
- CVSS: 8.1 (high)
- EPSS: 86.16% chance of exploitation in the next 30 days
- CISA KEV: Not listed
- Published: 2018-03-26
What LogPulse has for it
- Detection rule: Yes, published
- Agent check (vulnerable version): No
- Mitigation: Yes, see below
How to mitigate it
Upgrade Apache HTTP Server to 2.4.30 or later
Patch or upgrade. From 2.4.30 a $ in a FilesMatch expression no longer matches a trailing newline, so an uploaded file named with %0a cannot slip past an upload restriction and run as PHP (CVE-2017-15715).
Applies to: Apache HTTP Server 2.4.0 to 2.4.29 with FilesMatch based upload or handler rules.
- Check the version with httpd -v or apache2 -v.
- Install the current Apache HTTP Server 2.4 package from your distribution or apache.org.
- Restart Apache and check that sites load.
- Where upload folders are protected with FilesMatch, also turn off script execution in those folders (php_admin_flag engine off or a Directory block).
Sources:
Source data: NIST NVD, CISA KEV and FIRST EPSS. LogPulse processes new CVEs every hour.
We build every detection with great care, but no two environments are the same. Log sources, parsing and configuration differ, so test a detection in your own environment before you rely on it.