esm.sh: web.NewHandler allows arbitrary file read via encoded dot-segment path traversal
CVE-2026-102657Published 6 Nov 2026, 20:49 UTC
Real-world risk
8.0/ 10High
Patch this week; within 48 h if Internet-facing
PreliminaryFrom the CVSS vector only · confidence low
CVSS
7.5
scored by the vendor (CNA), CVSS 3.1
In plain words
No plain-language summary yet. The original description is below.
Original description (from GitHub_M)
esm.sh is a no-build content delivery network (CDN) for web development. Prior to server version 137_7, the documented web.NewHandler static file server in web/handler.go joins the URL-decoded r.URL.Path with Config.AppDir without verifying that the result remains inside the configured application directory. URL-encoded dot segments such as %2e%2e bypass the plain traversal redirect performed by Go's ServeMux, allowing an unauthenticated remote attacker to make the server open and return files outside Config.AppDir that are readable by the server process. The confirmed impact is file disclosure only, and the issue is reachable with Dev disabled. This issue is fixed in server version 137_7.
Am I affected?
| Product | Affected versions (from the sources) | Fixed in |
|---|---|---|
| esm.shNiche | < 137_7 | 137_7 |
What to do
Update to a fixed version: 137_7.
Why this score
| Factor | Value | Evidence | × |
|---|---|---|---|
| Impact | Major data exposureReads secrets, credentials, databases, arbitrary files | From the CVSS vector | 0.80 |
| Attacker position | InternetAnyone on the Internet can reach a typical deployment | From the CVSS vector | 1.00 |
| Privileges needed | NoneNo account | From the CVSS vector | 1.00 |
| Victim interaction | NoneNothing | From the CVSS vector | 1.00 |
| Configuration | DefaultOut-of-the-box installs are vulnerable | From the CVSS vector | 1.00 |
| Reliability | ReliableDeterministic: injection, logic bug, path traversal | From the CVSS vector | 1.00 |
Threat level T4: Weaponized (× 1.00)
A Metasploit module, a Nuclei template, or a verified Exploit-DB entry
EPSS 4.0% chance of exploitation in 30 days (percentile 91), as of 2026-12-06.
The arithmetic
- Prerequisites multiplied together1.000
- Threat T4: Weaponized1.000
- 10 × impact 0.8 × prerequisites 1 × threat 18.000
- Rounded to one decimal between 0.1 and 108.0
Exploitation and evidence timeline
- 6 Nov 2026 Published
- 3 Dec 2026 Nuclei scanner template first seen
- 3 Dec 2026 Reference tagged as exploit first seen
- 3 Dec 2026 CISA SSVC: proof of concept first seen
- 3 Dec 2026 Risk 8.0 (cvss fallback)
Weakness
CWE-22
References
- https://github.com/esm-dev/esm.sh/security/advisories/GHSA-g3c2-rjq2-c763exploit, vendor-advisory
- https://github.com/esm-dev/esm.sh/pull/1376misc
- https://github.com/esm-dev/esm.sh/commit/468b6b2a4b4dfec334cf6b33b01fcd4e5cd93bedmisc
- https://github.com/esm-dev/esm.sh/commit/fc3b345e73aeaa0b7a05b6f27d91c05fdf5f9b53misc
- https://github.com/esm-dev/esm.sh/releases/tag/v137_7misc
- CVE-2026-102657 on CVE.org