Description
esm.sh is a nobuild content delivery network(CDN) for modern web development. In 136 and earlier, a path-traversal flaw in the handling of the X-Zone-Id HTTP header allows an attacker to cause the application to write files outside the intended storage location. The header value is used to build a filesystem path but is not properly canonicalized or restricted to the application’s storage base directory. As a result, supplying ../ sequences in X-Zone-Id causes files to be written to arbitrary directories. Version 136.1 contains a patch.
Affected products
| Vendor | Product | Affected | Fixed |
|---|---|---|---|
| esm-dev | esm.sh | <= 136 | — |
Fixed in Linux distributions
Distributions backport fixes, so the version that fixes this vulnerability differs per release — upgrade to at least the version shown. From the distributions' security trackers and advisories.
SUSE
Security tracker ↗| Release | Package | Fixed in | Advisory |
|---|---|---|---|
| SLES 15 SP6 | govulncheck-vulndb | 0.0.20251023T162509-150000.1.110.1 | SUSE-SU-2025:3799-1 |
openSUSE
Security tracker ↗| Release | Package | Fixed in | Advisory |
|---|---|---|---|
| openSUSE Tumbleweed | govulncheck-vulndb | 0.0.20250924T192141-1.1 | openSUSE-SU-2025:15576-1 |
| openSUSE Leap 16.0 | govulncheck-vulndb | 0.0.20260723T184607-160000.1.1 | openSUSE-SU-2026:21483-1 |
| openSUSE Leap 15.6 | govulncheck-vulndb | 0.0.20251023T162509-150000.1.110.1 | SUSE-SU-2025:3799-1 |
Public exploits
Exploit or proof-of-concept code for this vulnerability is publicly available, which lowers the bar for attackers. Treat it as a reason to patch sooner.
Exploit-DB 1
- esm-dev 136 - Path Traversal EDB-52461 · webapps · Dec 16, 2025
GitHub 1 repository
-
byteReaper77/CVE-2025-59342 ★ 1 · Sep 18, 2025
Exploit Path Traversal in esm-dev
Sources: PoC-in-GitHub, Metasploit Framework, Exploit-DB — updated daily. Only links are listed; no exploit code is hosted here.
Automated scanner template
A ready-made Nuclei template detects this vulnerability automatically. Vulnerabilities with public scanner templates are typically probed across the internet soon after the template appears — exposed systems should be patched first.
- esm.sh <= v136 - Arbitrary File Write via Path Traversal http/cves/2025/CVE-2025-59342.yaml
Source: projectdiscovery/nuclei-templates (MIT) — updated daily. Only links are listed.
Affected packages
| Ecosystem | Package | Affected | Fixed | Record |
|---|---|---|---|---|
| Go | github.com/esm-dev/esm.sh | < 136.1 | 136.1 | GHSA-g2h5-cvvr-7gmw |
| Go | github.com/esm-dev/esm.sh | all versions | — | GO-2025-3967 |
Advisories 3
- openSUSE-SU-2026:21483-1 Security update for govulncheck-vulndb SUSE / openSUSE Security Updates · Jul 31, 2026
- openSUSE-SU-2025:15576-1 govulncheck-vulndb-0.0.20250924T192141-1.1 on GA media SUSE / openSUSE Security Updates · Mar 23, 2026
- SUSE-SU-2025:3799-1 Security update for govulncheck-vulndb SUSE / openSUSE Security Updates · Feb 4, 2026