CVE-2024-38475: Apache HTTP Server mod_rewrite output escaping flaw (file mapping)
Exploited in the wild Critical 9.1 EPSS 100.0% Apache HTTP Server
Improper escaping of output in mod_rewrite lets an attacker map URLs to filesystem locations the server is allowed to serve but that no URL is meant to reach, leading to code execution or source code disclosure. Only RewriteRules in server context whose substitution starts with a backreference or variable are affected. Apache fixed it in 2.4.60 (1 July 2024); CISA added it to KEV on 1 May 2025.
- CVE-2024-38475CVE identifier
- 9.1CVSS 3.1 base score (critical)
- 2025-05-01added to CISA's exploited list (US federal deadline 2025-05-22)
- 100.0%EPSS: chance of exploitation in the next 30 days (higher than 100% of CVEs)
- 2024-07-01published
What do these terms mean? CVE · CVSS score · exploited (KEV) · EPSS · backported fix · all terms
What to do now
- Check whether you run Apache HTTP Server and which version (commands below).
- Install the fixed version for your system: see “Patch it” below.
- Restart Apache (apache2 or httpd).
- If you cannot patch today, apply the temporary mitigation below and patch as soon as possible.
- Because this flaw is being exploited, also check the server for signs of compromise.
Affected and fixed versions
Affected:
- Apache HTTP Server 2.4.0 through 2.4.59
Fixed in:
- Apache HTTP Server 2.4.60
Am I affected?
apache2 -v # Debian/Ubuntu
httpd -v # RHEL/Fedora
grep -rn 'RewriteRule' /etc/apache2 /etc/httpd 2>/dev/null
Patch it
Use the commands for your system. Distribution packages often keep an older version number with the fix backported, so compare with the fixed package versions in the table below, not only with the upstream version.
Debian
sudo apt update
sudo apt install --only-upgrade apache2
sudo systemctl restart apache2Ubuntu
sudo apt update
sudo apt install --only-upgrade apache2
sudo systemctl restart apache2RHEL, AlmaLinux, Rocky, Oracle
sudo dnf upgrade httpd
sudo systemctl restart httpdFedora
sudo dnf upgrade --refresh httpdSUSE / openSUSE
sudo zypper refresh
sudo zypper update apache2Amazon Linux
sudo dnf upgrade --releasever=latest httpdArch Linux
sudo pacman -SyuAlpine
apk update && apk upgrade apache2FreeBSD
pkg update && pkg upgrade apache24General update steps for every system are on the Linux and Unix & BSD pages; after updating, see which services to restart.
Fix status in Linux distributions
| Release | Package | Status | Fixed version / advisory |
|---|---|---|---|
| Debian 12 | apache2 | fixed | 2.4.61-1~deb12u1 |
| Debian 13 | apache2 | fixed | 2.4.60-1 |
| Debian testing | apache2 | fixed | 2.4.60-1 |
| Ubuntu 20.04 (ESM) | apache2 | fixed | 2.4.41-4ubuntu3.19 |
| Ubuntu 22.04 | apache2 | fixed | 2.4.52-1ubuntu4.10 |
| Ubuntu 18.04 (ESM) | apache2 | fixed | 2.4.29-1ubuntu4.27+esm3 |
| Ubuntu 24.04 | apache2 | fixed | 2.4.58-1ubuntu8.2 |
| Red Hat Enterprise Linux 9 | httpd-0:2.4.57-11.el9_4 | fixed | RHSA-2024:4726 |
| Red Hat Enterprise Linux 8 | httpd:2.4-8100020240712114234.489197e6 | fixed | RHSA-2024:4720 |
| Debian 12 (bookworm) | apache2 | fixed | 2.4.61-1~deb12u1 (DSA-5729-1) |
| Debian 11 (bullseye) | apache2 | fixed | 2.4.61-1~deb11u1 (DSA-5729-1) |
| Ubuntu 24.04 LTS | apache2 | fixed | 2.4.58-1ubuntu8.2 (USN-6885-1) |
| Ubuntu 22.04 LTS | apache2 | fixed | 2.4.52-1ubuntu4.10 (USN-6885-1) |
| Ubuntu 20.04 LTS | apache2 | fixed | 2.4.41-4ubuntu3.19 (USN-6885-1) |
| Ubuntu 18.04 LTS (ESM) | apache2 | fixed | 2.4.29-1ubuntu4.27+esm3 (USN-6885-3) |
| RHEL 9 | httpd | fixed | 2.4.57-11.el9_4 (RHSA-2024:4726) |
| RHEL 8 | httpd:2.4 module | fixed | 8100020240712114234 (RHSA-2024:4720) |
From the Debian security tracker, Ubuntu CVE tracker and Red Hat Security Data API, refreshed every few hours.
If you cannot patch yet
- No practical mitigation is known (Red Hat); update.
- After updating, some unsafe RewriteRules stop working; the UnsafePrefixStat rewrite flag re-enables the old behaviour only once the substitution is properly constrained.
CISA required action: Apply mitigations per vendor instructions, follow applicable BOD 22-01 guidance for cloud services, or discontinue use of the product if mitigations are unavailable.
This vulnerability affects a common open-source component, third-party library, or a protocol used by different products. Please check with specific vendors for information on patching status. For more information, please see: https://httpd.apache.org/security/vulnerabilities_24.html ; https://nvd.nist.gov/vuln/detail/CVE-2024-38475
Related vulnerabilities
Sources
- CVE record CVE-2024-38475
- NVD CVE-2024-38475
- CISA KEV entry CVE-2024-38475
- Debian security tracker CVE-2024-38475
- Ubuntu CVE page CVE-2024-38475
- Red Hat CVE page CVE-2024-38475
- Apache HTTP Server 2.4 vulnerabilities
- https://security.netapp.com/advisory/ntap-20240712-0001/
- CISA Known Exploited Vulnerabilities catalog
Page generated automatically from official sources on 2026-11-03 18:05 UTC and reviewed by an editor. Always confirm with your vendor's advisory.