# CVE-2024-56198: path-sanitizer allows bypassing the existing filters to achieve path-traversal vulnerability

- Severity: Critical 9.3 (CVSS:4.0, scored by GitHub_M) `CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:H/VI:H/VA:H/SC:N/SI:N/SA:N`
- Known to be exploited: not in CISA's catalogue, which lists only what CISA has confirmed
- Likelihood of exploitation in the next 30 days (EPSS): 0.74%, higher than 55% of CVEs (2026-12-01)
- Published: 2024-12-31T15:18:12.330Z
- Modified: 2026-06-17T08:11:50.033Z
- Also known as: GHSA-94p5-r7cc-3rpr
- Weaknesses: CWE-22
- SSVC (CISA-ADP): exploitation poc, automatable yes, technical impact total
- Assigned by: GitHub_M

## Description

path-sanitizer is a simple lightweight npm package for sanitizing paths to prevent Path Traversal. Prior to 3.1.0, the filters can be bypassed using .=%5c which results in a path traversal. This vulnerability is fixed in 3.1.0.

(As written by CVE List.)

## Affected

- cabraviva path-sanitizer: < 3.1.0
- path-sanitizer (npm): before 3.1.0

## Every score

- GitHub_M: CVSS:4.0 9.3 Critical `CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:H/VI:H/VA:H/SC:N/SI:N/SA:N`
- GitHub: CVSS:4.0 Critical `CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:H/VI:H/VA:H/SC:N/SI:N/SA:N`

## References

- <https://github.com/cabraviva/path-sanitizer/security/advisories/GHSA-94p5-r7cc-3rpr> (web)
- <https://github.com/cabraviva/path-sanitizer/commit/b6d2319eac910dffdfacc8460f5b5cc5a1518ead> (web)
- <https://www.loom.com/share/b766ece5193842848ce7562fcd559256?sid=fd826eb6-0eee-4601-bf0e-9cfee5c56e9d> (web)
- <https://nvd.nist.gov/vuln/detail/CVE-2024-56198> (advisory)
- <https://github.com/cabraviva/path-sanitizer> (package)

## Sources

- CVE List: [CVE-2024-56198](https://www.cve.org/CVERecord?id=CVE-2024-56198), CVE Terms of Use, modified 2024-12-31
- GitHub Advisory Database: [GHSA-94p5-r7cc-3rpr](https://github.com/advisories/GHSA-94p5-r7cc-3rpr), CC-BY-4.0, modified 2025-01-02
- NVD: [CVE-2024-56198](https://nvd.nist.gov/vuln/detail/CVE-2024-56198), Public domain, modified 2026-06-17

---

Page: https://cve.day/CVE-2024-56198 · Whole record: https://cve.day/CVE-2024-56198.json · Rebuilt by cve.day 2026-11-25T22:58:50.614Z
