Summary
tower-http's improper validation of Windows paths could lead to directory traversal attack
tower_http::services::fs::ServeDir didn't correctly validate Windows paths meaning paths like /foo/bar/c:/windows/web/screen/img101.png would be allowed and respond with the contents of c:/windows/web/screen/img101.png. Thus users could potentially read files anywhere on the filesystem. This only impacts Windows. Linux and other unix likes are not impacted by this.
Impact
Input manipulates file paths to reach files outside the intended directory, such as configuration or credential files. Typical impact: unauthorized file read or write outside the intended directory.
Affected versions
Security releases
Kodem intelligence
Severity tells you how bad this could be in the worst case. It does not tell you whether you are exposed. Exploitability and impact are functions of runtime truth: whether the vulnerable code is present, reachable, and actually executes in your application. A vulnerable package can sit in your dependency tree and never run.
Kodem, an Intelligent Application Security platform, uses runtime intelligence to reveal which vulnerabilities actually execute in production, so teams prioritize the ones that genuinely matter. Kodem's runtime-powered SCA identifies whether this CVE is reachable in your applications.
Already deployed Kodem?
See it in your environmentNew to Kodem? Get a demo →Remediation advice
tower-http to 0.2.1 or later; tower-http to 0.1.3 or later
Kodem Kai can prioritize this vulnerability in your dependency tree and generate a fix recommendation.
Frequently Asked Questions
- What is GHSA-WWH2-R387-G5RM? GHSA-WWH2-R387-G5RM is a medium-severity path traversal vulnerability in tower-http (rust), affecting versions >= 0.2.0, < 0.2.1. It is fixed in 0.2.1, 0.1.3. Input manipulates file paths to reach files outside the intended directory, such as configuration or credential files.
- Which versions of tower-http are affected by GHSA-WWH2-R387-G5RM? tower-http (rust) versions >= 0.2.0, < 0.2.1 is affected.
- Is there a fix for GHSA-WWH2-R387-G5RM? Yes. GHSA-WWH2-R387-G5RM is fixed in 0.2.1, 0.1.3. Upgrade to this version or later.
- Is GHSA-WWH2-R387-G5RM exploitable, and should I be worried? Whether GHSA-WWH2-R387-G5RM is exploitable in your environment depends on whether the vulnerable code is present and reachable. A CVSS score is a worst-case rating; it does not account for your specific deployment, configuration, or usage patterns. Kodem, an Intelligent Application Security platform, uses runtime intelligence to show which vulnerabilities actually execute in production, so you can focus on the ones that represent real risk. Get a demo
- What actually determines whether GHSA-WWH2-R387-G5RM is exploitable, and how bad it is? Exploitability and impact are not fixed properties of a CVE. They depend on runtime truth: whether the vulnerable code is present, reachable, and actually executes in your application. A high CVSS score on a dependency that never runs is not the same as real risk. Kodem, an Intelligent Application Security platform, uses runtime intelligence to reveal which vulnerabilities actually execute in production, so teams prioritize the ones that genuinely matter.
- How do I fix GHSA-WWH2-R387-G5RM?
- Upgrade
tower-httpto 0.2.1 or later - Upgrade
tower-httpto 0.1.3 or later
- Upgrade