CVE-2026-103061
Path traversal in Gleam via unvalidated package application names
Mitigation
- Upgrade Gleam to 1.19.2 or later.
Who should check
- Anyone running Gleam >= v0.32.4-elixir, < v1.19.2-elixir; >= v0.32.4-erlang, < v1.19.2-erlang; >= v0.32.4-node, < v1.19.2-node; >= v0.32.4-node-slim, < v1.19.2-node-slim; >= v0.32.4-elixir-slim, < v1.19.2-elixir-slim; >= v0.32.4-erlang-slim, < v1.19.2-erlang-slim; >= v0.32.4-erlang-alpine, < v1.19.2-erlang-alpine; >= v0.32.4-elixir-alpine, < v1.19.2-elixir-alpine; >= v0.32.4-node-alpine, < v1.19.2-node-alpine; >= v0.32.4-scratch, < v1.19.2-scratch
- Anyone running Gleam >= 0.32.4, < 1.19.2
- Anyone running Gleam >= d13f27ee80aae7a521d2e9433c4deaf53f892574, < *
Vulnerability facts
- Affected
- Gleam >= v0.32.4-elixir, < v1.19.2-elixir; >= v0.32.4-erlang, < v1.19.2-erlang; >= v0.32.4-node, < v1.19.2-node; >= v0.32.4-node-slim, < v1.19.2-node-slim; >= v0.32.4-elixir-slim, < v1.19.2-elixir-slim; >= v0.32.4-erlang-slim, < v1.19.2-erlang-slim; >= v0.32.4-erlang-alpine, < v1.19.2-erlang-alpine; >= v0.32.4-elixir-alpine, < v1.19.2-elixir-alpine; >= v0.32.4-node-alpine, < v1.19.2-node-alpine; >= v0.32.4-scratch, < v1.19.2-scratch; Gleam >= 0.32.4, < 1.19.2; Gleam >= d13f27ee80aae7a521d2e9433c4deaf53f892574, < *
- Fixed in
- Gleam 1.19.2
- Exploited in the wild
- Not in CISA KEV
- Public exploit / PoC
- None known
- Remote exploitation
- Remote, no login needed
- CVSS
- 5.9 (v4.0, CNA)CVSS:4.0/AV:N/AC:L/AT:P/PR:N/UI:A/VC:N/VI:N/VA:H/SC:N/SI:N/SA:NOpen in CVSS calculator
Show all 11 CVSS metrics
- Attack vector: Network
- Attack complexity: Low
- Attack requirements: Present
- Privileges required: None
- User interaction: Active
- Confidentiality impact: None
- Integrity impact: None
- Availability impact: High
- Confidentiality impact on other systems: None
- Integrity impact on other systems: None
- Availability impact on other systems: None
- EPSS
- 0.60% chance of exploitation in 30 days (percentile 43, 2026-11-28)
- CWE
- CWE-22
- Modified
Description
Improper Limitation of a Pathname to a Restricted Directory ('Path Traversal') vulnerability in gleam-lang gleam allows a malicious package publisher to delete a directory outside the project's build directory when a developer builds a project. A Hex package release's metadata carries an app field with the release's OTP application name. Gleam reads this field from the hex.pm release API when it downloads dependencies and uses it as the package's build directory name without validating it (hex_manifest_package in compiler-cli/src/dependencies.rs, ProjectPaths::build_directory_for_package). When a dependency fails to compile, Gleam deletes that directory with remove_dir_all. hex.pm didn't restrict the field to a directory name before 2026-10-12, so a publisher could set it to a value such as ../../../../target or an absolute path. When a project depends on such a release directly or transitively and the release fails to compile, gleam build, gleam check, gleam run, gleam test or gleam export deletes the directory the name resolves to. For a pure Gleam package no publisher code runs. This issue affects gleam: from 0.32.4 before 1.19.2.
Affected and fixed versions
| Package / product | Affected | Fixed | Source |
|---|---|---|---|
| Gleam | >= v0.32.4-elixir, < v1.19.2-elixir; >= v0.32.4-erlang, < v1.19.2-erlang; >= v0.32.4-node, < v1.19.2-node; >= v0.32.4-node-slim, < v1.19.2-node-slim; >= v0.32.4-elixir-slim, < v1.19.2-elixir-slim; >= v0.32.4-erlang-slim, < v1.19.2-erlang-slim; >= v0.32.4-erlang-alpine, < v1.19.2-erlang-alpine; >= v0.32.4-elixir-alpine, < v1.19.2-elixir-alpine; >= v0.32.4-node-alpine, < v1.19.2-node-alpine; >= v0.32.4-scratch, < v1.19.2-scratch | — | cvelist |
| Gleam | >= 0.32.4, < 1.19.2 | — | cvelist |
| Gleam | >= d13f27ee80aae7a521d2e9433c4deaf53f892574, < * | — | cvelist |
Check your systems with an agent
Paste this into Claude Code, Cursor or another coding agent. It only reads; it changes nothing.
Check whether anything I run is affected by CVE-2026-103061. Work read-only: do not install, upgrade, delete or change anything. Details: https://flawdb.com/CVE-2026-103061.md Affected: Gleam >= v0.32.4-elixir, < v1.19.2-elixir; >= v0.32.4-erlang, < v1.19.2-erlang; >= v0.32.4-node, < v1.19.2-node; >= v0.32.4-node-slim, < v1.19.2-node-slim; >= v0.32.4-elixir-slim, < v1.19.2-elixir-slim; >= v0.32.4-erlang-slim, < v1.19.2-erlang-slim; >= v0.32.4-erlang-alpine, < v1.19.2-erlang-alpine… Fixed in: Gleam 1.19.2 Steps: 1. Search this machine and project for Gleam: dependency manifests and lockfiles, installed packages, container images and running services. 2. For each match, note the installed version and whether it is inside the affected range. 3. Report a table: location, installed version, affected (yes / no / unsure), evidence. If affected, say which fixed version or mitigation from the details link applies, but don't apply it.
References
Patches
FAQ
Is CVE-2026-103061 being exploited?
There is no confirmed exploitation: CVE-2026-103061 is not in the CISA Known Exploited Vulnerabilities catalog. No public exploit code is known. EPSS estimates a 0.60% chance of exploitation in the next 30 days (as of 2026-11-28).
How serious is CVE-2026-103061?
Medium: CVSS 5.9 (v4.0, scored by CNA). Remote, no login needed. A user has to take an action, such as opening a link, for the attack to work.
Which versions are affected by CVE-2026-103061?
Gleam >= v0.32.4-elixir, < v1.19.2-elixir; >= v0.32.4-erlang, < v1.19.2-erlang; >= v0.32.4-node, < v1.19.2-node; >= v0.32.4-node-slim, < v1.19.2-node-slim; >= v0.32.4-elixir-slim, < v1.19.2-elixir-slim; >= v0.32.4-erlang-slim, < v1.19.2-erlang-slim; >= v0.32.4-erlang-alpine, < v1.19.2-erlang-alpine; >= v0.32.4-elixir-alpine, < v1.19.2-elixir-alpine; >= v0.32.4-node-alpine, < v1.19.2-node-alpine; >= v0.32.4-scratch, < v1.19.2-scratch; Gleam >= 0.32.4, < 1.19.2; Gleam >= d13f27ee80aae7a521d2e9433c4deaf53f892574, < *.
Is there a fix for CVE-2026-103061?
Yes. Fixed in Gleam 1.19.2. Upgrade Gleam to 1.19.2 or later.
How do I check if I'm affected by CVE-2026-103061?
Find where you use the affected software (dependency lockfiles, installed packages, container images, servers) and compare the installed version with the affected range above. The agent prompt on this page does this read-only.