Security mailing lists by PureSourceCode

CVE-2026-43965

MEDIUM 5.6CVSS 4.0

Path Traversal in build/packages/packages.toml Allows Arbitrary Directory Deletion

Path traversal vulnerability in Gleam's dependency management allows arbitrary directory deletion via malicious build/packages/packages.toml content.

Package keys read from build/packages/packages.toml by LocalPackages::read_from_disc are passed without validation to paths.build_packages_package(), which constructs a filesystem path by joining the project build directory with the attacker-controlled key. The resulting path is then passed to fs::delete_directory (which calls remove_dir_all). No check is performed to ensure the path remains within the intended build/packages/ directory. Both absolute paths and relative traversal sequences (e.g. ../) are accepted as package keys, allowing deletion of arbitrary directories.

An attacker who can cause a victim to run gleam deps download on a project containing a malicious build/packages/packages.toml (e.g. by committing the normally-gitignored file to a repository) can cause arbitrary directories on the victim's system to be recursively deleted.

This issue affects gleam: from 0.18.0-rc1 before 1.17.0.

Published
2 Jun 2026
Last modified
20 Nov 2026
Assigned by
6b3ad84c-e1a6-4bf7-a703-f496b71e49db
NVD status
Deferred
Weakness
CWE-22
Sources
NVDJSONCVE ListJSON

Scores

SourceScored byVersionScoreVector / decision
NVD 6b3ad84c-e1a6-4bf7-a703-f496b71e49db (Secondary) CVSS 4.0 MEDIUM 5.6 CVSS:4.0/AV:L/AC:L/AT:P/PR:N/UI:A/VC:N/VI:N/VA:H/SC:N/SI:N/SA:N/E:X/CR:X/IR:X/AR:X/MAV:X/MAC:X/MAT:X/MPR:X/MUI:X/MVC:X/MVI:X/MVA:X/MSC:X/MSI:X/MSA:X/S:X/AU:X/R:X/V:X/RE:X/U:X
CVE List EEF CVSS 4.0 MEDIUM 5.6 CVSS:4.0/AV:L/AC:L/AT:P/PR:N/UI:A/VC:N/VI:N/VA:H/SC:N/SI:N/SA:N
CVE List CISA-ADP SSVC Exploitation: poc; Automatable: no; Technical Impact: partial

Affected

SourceVendor / ecosystemProduct / packageAffected versionsFixed in
CVE List https://ghcr.io gleam-lang/gleam
cpe:2.3:a:gleam-lang:gleam:*:*:*:*:*:*:*:*
>= v0.18.0-rc1-elixir, < v1.17.0-elixir; >= v0.18.0-rc1-erlang, < v1.17.0-erlang; >= v0.18.0-rc1-node, < v1.17.0-node; >= v0.18.0-rc1-node-slim, < v1.17.0-node-slim; >= v0.18.0-rc1-elixir-slim, < v1.17.0-elixir-slim; >= v0.18.0-rc1-erlang-slim, < v1.17.0-erlang-slim; >= v0.18.0-rc1-erlang-alpine, < v1.17.0-erlang-alpine; >= v0.18.0-rc1-elixir-alpine, < v1.17.0-elixir-alpine; >= v0.18.0-rc1-node-alpine, < v1.17.0-node-alpine; >= v0.18.0-rc1-scratch, < v1.17.0-scratch v1.17.0-elixir, v1.17.0-erlang, v1.17.0-node, v1.17.0-node-slim, v1.17.0-elixir-slim, v1.17.0-erlang-slim, v1.17.0-erlang-alpine, v1.17.0-elixir-alpine, v1.17.0-node-alpine, v1.17.0-scratch
CVE List Gleam gleam
cpe:2.3:a:gleam-lang:gleam:*:*:*:*:*:*:*:*
>= 0.18.0-rc1, < 1.17.0 1.17.0
CVE List https://github.com gleam-lang/gleam
cpe:2.3:a:gleam-lang:gleam:*:*:*:*:*:*:*:*
>= ed7aec0484f10d60978b63788c8a6497590855ab, < 690ca069817bee5f77a28fc3e360627c1da19291 690ca069817bee5f77a28fc3e360627c1da19291

References

History

  • 25 Nov 2026 20:32 UTC · CVE List: first stored (published 2 Jun 2026)
  • 25 Nov 2026 20:10 UTC · NVD: first stored (published 2 Jun 2026)
An unhandled error has occurred. Reload ×

Rejoining the server...

Rejoin failed... trying again in seconds.

Failed to rejoin.
Please retry or reload the page.

The session has been paused by the server.

Failed to resume the session.
Please retry or reload the page.