CVE-2026-32685
Path Traversal in gleam docs build via documentation.pages Allows Arbitrary File Read and Write
Mitigation
- Upgrade Gleam to 1.17.0 or later.
- Upgrade Gleam to 81570611906b6b0039c948037094d09a68700f3a or later.
- Vendor workaround: * Avoid running gleam docs build on untrusted projects
- * Review documentation.pages entries in gleam.toml before generating documentation
- * Run documentation generation in a restricted or isolated environment (e.g. containers)
Who should check
- Anyone running Gleam >= v1.16.0-elixir, < v1.17.0-elixir; >= v1.16.0-erlang, < v1.17.0-erlang; >= v1.16.0-node, < v1.17.0-node; >= v1.16.0-node-slim, < v1.17.0-node-slim; >= v1.16.0-elixir-slim, < v1.17.0-elixir-slim; >= v1.16.0-erlang-slim, < v1.17.0-erlang-slim; >= v1.16.0-erlang-alpine, < v1.17.0-erlang-alpine; >= v1.16.0-elixir-alpine, < v1.17.0-elixir-alpine; >= v1.16.0-node-alpine, < v1.17.0-node-alpine; >= v1.16.0-scratch, < v1.17.0-scratch
- Anyone running Gleam >= 1.16.0, < 1.17.0
- Anyone running Gleam >= 61ed8deb6572b5591ad17d6302c1a38607522f16, < 81570611906b6b0039c948037094d09a68700f3a
Vulnerability facts
- Affected
- Gleam >= v1.16.0-elixir, < v1.17.0-elixir; >= v1.16.0-erlang, < v1.17.0-erlang; >= v1.16.0-node, < v1.17.0-node; >= v1.16.0-node-slim, < v1.17.0-node-slim; >= v1.16.0-elixir-slim, < v1.17.0-elixir-slim; >= v1.16.0-erlang-slim, < v1.17.0-erlang-slim; >= v1.16.0-erlang-alpine, < v1.17.0-erlang-alpine; >= v1.16.0-elixir-alpine, < v1.17.0-elixir-alpine; >= v1.16.0-node-alpine, < v1.17.0-node-alpine; >= v1.16.0-scratch, < v1.17.0-scratch; Gleam >= 1.16.0, < 1.17.0; Gleam >= 61ed8deb6572b5591ad17d6302c1a38607522f16, < 81570611906b6b0039c948037094d09a68700f3a
- Fixed in
- Gleam 1.17.0, Gleam 81570611906b6b0039c948037094d09a68700f3a
- Exploited in the wild
- Not in CISA KEV
- Public exploit / PoC
- None known
- Remote exploitation
- Not remotely exploitable (local or adjacent access needed)
- CVSS
- 4.6 (v4.0, CNA)CVSS:4.0/AV:L/AC:L/AT:N/PR:N/UI:A/VC:L/VI:L/VA:N/SC:N/SI:N/SA:NOpen in CVSS calculator
Show all 11 CVSS metrics
- Attack vector: Local
- Attack complexity: Low
- Attack requirements: None
- Privileges required: None
- User interaction: Active
- Confidentiality impact: Low
- Integrity impact: Low
- Availability impact: None
- Confidentiality impact on other systems: None
- Integrity impact on other systems: None
- Availability impact on other systems: None
- EPSS
- 0.19% chance of exploitation in 30 days (percentile 5, 2026-11-26)
- CWE
- CWE-22
- Modified
Description
Path traversal vulnerability in Gleam's handling of custom documentation pages allows arbitrary file read and file write outside the intended documentation output directory. The documentation.pages entries from gleam.toml are incorporated into filesystem paths without sufficient validation or confinement to the intended project and documentation output directories. The documentation.pages[].path field can be used to write generated documentation files outside the intended build/dev/docs/<package>/ output directory. The documentation.pages[].source field can be used to read files outside the project directory and embed their contents into generated documentation output. An attacker who can convince a victim to run gleam docs build on an untrusted project, or with untrusted gleam.toml content, can cause local files readable by the victim to be included in generated documentation artifacts, and can cause generated documentation files to be written outside the intended docs output directory. This issue affects gleam: from 1.16.0 before 1.17.0.
Affected and fixed versions
| Package / product | Affected | Fixed | Source |
|---|---|---|---|
| Gleam | >= v1.16.0-elixir, < v1.17.0-elixir; >= v1.16.0-erlang, < v1.17.0-erlang; >= v1.16.0-node, < v1.17.0-node; >= v1.16.0-node-slim, < v1.17.0-node-slim; >= v1.16.0-elixir-slim, < v1.17.0-elixir-slim; >= v1.16.0-erlang-slim, < v1.17.0-erlang-slim; >= v1.16.0-erlang-alpine, < v1.17.0-erlang-alpine; >= v1.16.0-elixir-alpine, < v1.17.0-elixir-alpine; >= v1.16.0-node-alpine, < v1.17.0-node-alpine; >= v1.16.0-scratch, < v1.17.0-scratch | — | cvelist |
| Gleam | >= 1.16.0, < 1.17.0 | — | cvelist |
| Gleam | >= 61ed8deb6572b5591ad17d6302c1a38607522f16, < 81570611906b6b0039c948037094d09a68700f3a | — | 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-32685. Work read-only: do not install, upgrade, delete or change anything. Details: https://flawdb.com/CVE-2026-32685.md Affected: Gleam >= v1.16.0-elixir, < v1.17.0-elixir; >= v1.16.0-erlang, < v1.17.0-erlang; >= v1.16.0-node, < v1.17.0-node; >= v1.16.0-node-slim, < v1.17.0-node-slim; >= v1.16.0-elixir-slim, < v1.17.0-elixir-slim; >= v1.16.0-erlang-slim, < v1.17.0-erlang-slim; >= v1.16.0-erlang-alpine, < v1.17.0-erlang-alpine… Fixed in: Gleam 1.17.0, Gleam 81570611906b6b0039c948037094d09a68700f3a 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-32685 being exploited?
There is no confirmed exploitation: CVE-2026-32685 is not in the CISA Known Exploited Vulnerabilities catalog. No public exploit code is known. EPSS estimates a 0.19% chance of exploitation in the next 30 days (as of 2026-11-26).
How serious is CVE-2026-32685?
Medium: CVSS 4.6 (v4.0, scored by CNA). Not remotely exploitable (local or adjacent access 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-32685?
Gleam >= v1.16.0-elixir, < v1.17.0-elixir; >= v1.16.0-erlang, < v1.17.0-erlang; >= v1.16.0-node, < v1.17.0-node; >= v1.16.0-node-slim, < v1.17.0-node-slim; >= v1.16.0-elixir-slim, < v1.17.0-elixir-slim; >= v1.16.0-erlang-slim, < v1.17.0-erlang-slim; >= v1.16.0-erlang-alpine, < v1.17.0-erlang-alpine; >= v1.16.0-elixir-alpine, < v1.17.0-elixir-alpine; >= v1.16.0-node-alpine, < v1.17.0-node-alpine; >= v1.16.0-scratch, < v1.17.0-scratch; Gleam >= 1.16.0, < 1.17.0; Gleam >= 61ed8deb6572b5591ad17d6302c1a38607522f16, < 81570611906b6b0039c948037094d09a68700f3a.
Is there a fix for CVE-2026-32685?
Yes. Fixed in Gleam 1.17.0, Gleam 81570611906b6b0039c948037094d09a68700f3a. Upgrade Gleam to 1.17.0 or later. Upgrade Gleam to 81570611906b6b0039c948037094d09a68700f3a or later. Vendor workaround: * Avoid running gleam docs build on untrusted projects * Review documentation.pages entries in gleam.toml before generating documentation * Run documentation generation in a restricted or isolated environment (e.g. containers)
How do I check if I'm affected by CVE-2026-32685?
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.