{"id":"GHSA-wwh2-r387-g5rm","aliases":["GHSA-wwh2-r387-g5rm"],"related":[],"kind":"vulnerability","state":"published","title":"tower-http's improper validation of Windows paths could lead to directory traversal attack","summary":"`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.","summaryFormat":"markdown","summarySource":"ghsa","descriptions":[{"lang":"en","text":"`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.","format":"markdown","source":"ghsa"}],"published":"2022-06-17T00:26:05.000Z","modified":"2023-06-13T22:06:25.000Z","severity":{"scorer":"GitHub","scheme":"rating","rating":"MEDIUM"},"severities":[{"scorer":"GitHub","scheme":"rating","rating":"MEDIUM"}],"cwes":["CWE-22"],"affected":[{"ranges":[{"type":"semver","introduced":"0.2.0","status":"affected","fixed":"0.2.1"}],"ecosystem":"crates.io","package":"tower-http","purl":"pkg:cargo/tower-http","source":"ghsa"},{"ranges":[{"type":"semver","introduced":"0","status":"affected","fixed":"0.1.3"}],"ecosystem":"crates.io","package":"tower-http","purl":"pkg:cargo/tower-http","source":"ghsa"}],"references":[{"url":"https://github.com/tower-rs/tower-http/pull/204","tags":["web"],"sources":["ghsa"]},{"url":"https://github.com/tower-rs/tower-http","tags":["package"],"sources":["ghsa"]},{"url":"https://rustsec.org/advisories/RUSTSEC-2021-0135.html","tags":["web"],"sources":["ghsa"]}],"credits":[],"sources":[{"source":"ghsa","name":"GitHub Advisory Database","id":"GHSA-wwh2-r387-g5rm","url":"https://github.com/advisories/GHSA-wwh2-r387-g5rm","licence":"CC-BY-4.0","modified":"2023-06-13T22:06:25.000Z"}],"updatedAt":"2026-11-25T22:56:42.862Z"}