Skip to content

CVE-2026-32146 Improper Path Validation in Git Dependency Handling Allows Arbitrary File System Modification

HighCVSS 8.3 EPSS 0.26%
Published
Updated
Exploit status
No public exploit known
CISA SSVC
Proof of concept public · automatable: no · technical impact: partial
Technology
Red Hat

Description

Improper path validation vulnerability in the Gleam compiler's handling of git dependencies allows arbitrary file system modification during dependency download.

Dependency names from gleam.toml and manifest.toml are incorporated into filesystem paths without sufficient validation or confinement to the intended dependency directory, allowing attacker-controlled paths (via relative traversal such as ../ or absolute paths) to target filesystem locations outside that directory. When resolving git dependencies (e.g. via gleam deps download), the computed path is used for filesystem operations including directory deletion and creation.

This vulnerability occurs during the dependency resolution and download phase, which is generally expected to be limited to fetching and preparing dependencies within a confined directory. A malicious direct or transitive git dependency can exploit this issue to delete and overwrite arbitrary directories outside the intended dependency directory, including attacker-chosen absolute paths, potentially causing data loss. In some environments, this may be further leveraged to achieve code execution, for example by overwriting git hooks or shell configuration files.

This issue affects gleam: from 1.9.0-rc1 before 1.15.4 and from 1.16.0-rc1 before 1.16.0-rc2.

Upgrade path

3 packages: 2 fixed.

PackageAffectedFixed inStatus
gleam-lang gleam >= 1.9.0-rc1, < 1.15.4; >= 1.16.0-rc1, < 1.16.0-rc2; >= a4fde22445ab8e5cc79c2ff48971616cb570702c, < 2dc0467f822c75de94697a912755d172928ee40a; >= v1.9.0-rc1-elixir, < v1.15.4-elixir +19 more 1.15.4, 1.16.0-rc2, 2dc0467f822c75de94697a912755d172928ee40a, v1.15.4-elixir, v1.15.4-elixir-alpine, v1.15.4-elixir-slim, v1.15.4-erlang, v1.15.4-erlang-alpine, v1.15.4-erlang-slim, v1.15.4-node, v1.15.4-node-alpine, v1.15.4-node-slim, v1.15.4-scratch, v1.16.0-rc2-elixir, v1.16.0-rc2-elixir-alpine, v1.16.0-rc2-elixir-slim, v1.16.0-rc2-erlang, v1.16.0-rc2-erlang-alpine, v1.16.0-rc2-erlang-slim, v1.16.0-rc2-node, v1.16.0-rc2-node-alpine, v1.16.0-rc2-node-slim, v1.16.0-rc2-scratch Fixed
lpil gleam >= 1.9.0, < 1.15.4 1.15.4 Fixed
redhat enterprise linux = 7; = 8; = 9; = 10 No fix listed Versions listed

Affected products

ProductAffected versionsFixed in
gleam-lang gleam >= v1.9.0-rc1-elixir, < v1.15.4-elixir v1.15.4-elixir
gleam-lang gleam >= v1.9.0-rc1-erlang, < v1.15.4-erlang v1.15.4-erlang
gleam-lang gleam >= v1.9.0-rc1-node, < v1.15.4-node v1.15.4-node
gleam-lang gleam >= v1.9.0-rc1-node-slim, < v1.15.4-node-slim v1.15.4-node-slim
gleam-lang gleam >= v1.9.0-rc1-elixir-slim, < v1.15.4-elixir-slim v1.15.4-elixir-slim
gleam-lang gleam >= v1.9.0-rc1-erlang-slim, < v1.15.4-erlang-slim v1.15.4-erlang-slim
gleam-lang gleam >= v1.9.0-rc1-erlang-alpine, < v1.15.4-erlang-alpine v1.15.4-erlang-alpine
gleam-lang gleam >= v1.9.0-rc1-elixir-alpine, < v1.15.4-elixir-alpine v1.15.4-elixir-alpine
gleam-lang gleam >= v1.9.0-rc1-node-alpine, < v1.15.4-node-alpine v1.15.4-node-alpine
gleam-lang gleam >= v1.9.0-rc1-scratch, < v1.15.4-scratch v1.15.4-scratch
gleam-lang gleam >= v1.16.0-rc1-elixir, < v1.16.0-rc2-elixir v1.16.0-rc2-elixir
gleam-lang gleam >= v1.16.0-rc1-erlang, < v1.16.0-rc2-erlang v1.16.0-rc2-erlang
gleam-lang gleam >= v1.16.0-rc1-node, < v1.16.0-rc2-node v1.16.0-rc2-node
gleam-lang gleam >= v1.16.0-rc1-node-slim, < v1.16.0-rc2-node-slim v1.16.0-rc2-node-slim
gleam-lang gleam >= v1.16.0-rc1-elixir-slim, < v1.16.0-rc2-elixir-slim v1.16.0-rc2-elixir-slim
gleam-lang gleam >= v1.16.0-rc1-erlang-slim, < v1.16.0-rc2-erlang-slim v1.16.0-rc2-erlang-slim
gleam-lang gleam >= v1.16.0-rc1-erlang-alpine, < v1.16.0-rc2-erlang-alpine v1.16.0-rc2-erlang-alpine
gleam-lang gleam >= v1.16.0-rc1-elixir-alpine, < v1.16.0-rc2-elixir-alpine v1.16.0-rc2-elixir-alpine
gleam-lang gleam >= v1.16.0-rc1-node-alpine, < v1.16.0-rc2-node-alpine v1.16.0-rc2-node-alpine
gleam-lang gleam >= v1.16.0-rc1-scratch, < v1.16.0-rc2-scratch v1.16.0-rc2-scratch
gleam-lang gleam >= 1.9.0-rc1, < 1.15.4 1.15.4
gleam-lang gleam >= 1.16.0-rc1, < 1.16.0-rc2 1.16.0-rc2
gleam-lang gleam >= a4fde22445ab8e5cc79c2ff48971616cb570702c, < 2dc0467f822c75de94697a912755d172928ee40a 2dc0467f822c75de94697a912755d172928ee40a
redhat enterprise linux = 10 No fix listed
redhat enterprise linux = 7 No fix listed
Show 3 more
ProductAffected versionsFixed in
redhat enterprise linux = 8 No fix listed
redhat enterprise linux = 9 No fix listed
lpil gleam >= 1.9.0, < 1.15.4 1.15.4

References