# CVE-2026-39245: kevva decompress directory traversal in path validation

Source: https://junglewise.ai/threats/cve-2026-39245-kevva-decompress-directory-traversal-in-path-validation  
Publisher: Junglewise Threat Intelligence, https://junglewise.ai/threats  
Published: 2026-07-09. Updated: 2026-07-09  
License: CC BY 4.0 with a link back

CVE-2026-39245 · Severity: info · CVSS 9.8 · Published 2026-07-09

The 'decompress' library, a popular tool for extracting archive files in Node.js applications, contains a security flaw in how it validates file paths. An attacker can provide a specially crafted archive that, when extracted, writes files to unintended locations on the server's disk. This could allow an attacker to overwrite critical system files or application configurations, potentially leading to full system compromise or data loss.

Technologies: [Kevin Mårtensson Decompress](https://junglewise.ai/threats/technologies/decompress). Vendors: [Kevin Mårtensson](https://junglewise.ai/threats/vendors/kevin-m-rtensson).

## Quick answers

**Is CVE-2026-39245 exploited in the wild?** No. Junglewise Threat Intelligence has no report of CVE-2026-39245 being exploited in the wild.

**How severe is CVE-2026-39245?** Informational severity, with a CVSS score of 9.8, published 9 July 2026.

**Which products and versions are affected?** Kevin Mårtensson Decompress < 4.2.2.

**Is there a fix for CVE-2026-39245?** No fixed version is recorded yet. Check the vendor's advisory in the references below. If you run it, Junglewise drafts a mitigation that fits your setup and applies it once you approve, with senior security engineers behind it.

**How is CVE-2026-39245 attacked?** It is attacked over the network, in a software library.

**Am I affected by CVE-2026-39245?** Check whether you run Kevin Mårtensson Decompress at an affected version. Junglewise does that check for you around the clock: connect your code, cloud and domains, and it matches new vulnerabilities like this one against what you actually run and tells you when one reaches you.

## Technical details

The vulnerability exists in index.js within the safeMakeDir function and extraction path validation logic. The library uses String.indexOf() to verify if a resolved path is within the output directory but fails to enforce a path separator boundary. For example, a check for '/tmp/app' would incorrectly validate '/tmp/app_config' because the latter starts with the same string. When combined with unvalidated symlink creation, a remote attacker can bypass intended directory restrictions to perform arbitrary file writes. This is a bypass of the previous fix for CVE-2020-12265. The issue is resolved in version 4.2.2 by ensuring a path separator is appended during the containment check.

## Affected products

- kevva decompress < 4.2.2

## Timeline

- 2026-07-04: disclosed: Issue reported on GitHub by devploit
- 2026-07-09: advisory: CVE-2026-39245 published

## References

- [https://github.com/kevva/decompress](https://github.com/kevva/decompress)
- [https://github.com/kevva/decompress/issues/115](https://github.com/kevva/decompress/issues/115)
- [https://www.npmjs.com/package/decompress](https://www.npmjs.com/package/decompress)

## Related threats

- [XhmikosR decompress path traversal and privilege escalation during extraction](https://junglewise.ai/threats/cve-2026-53486-xhmikosr-decompress-path-traversal-and-privilege-escalation)
- [kevva decompress arbitrary symlink creation during extraction](https://junglewise.ai/threats/cve-2026-39246-kevva-decompress-arbitrary-symlink-creation-during-extraction)
- [kevva decompress arbitrary hardlink creation in archive extraction](https://junglewise.ai/threats/cve-2026-39243-kevva-decompress-arbitrary-hardlink-creation-in-archive)
- [kevva decompress Arbitrary File Write via Zip Slip bypass](https://junglewise.ai/threats/cve-2026-10732-kevva-decompress-arbitrary-file-write-via-zip-slip-bypass)
