CVE-2026-42795
Last modified
CVE-2026-42795 is a medium-severity vulnerability rated 5.1/10 on the CVSS scale. Symlink following vulnerability in Gleam's Hex package export allows files outside the project root to be embedded in the generated package tarball. The file collection helpers (gleam_files, native_files, private_files) in compiler-cli/src/fs.rs use follow_links(true) when walking publishable directories such as src/ and priv/. The collected paths are added to the package archive via add_path_to_tar in compiler-cli/src/publish.rs without verifying that the resolved target remains within the project root. EPSS estimates a 0.13% chance of exploitation in the next 30 days.
Description
Symlink following vulnerability in Gleam's Hex package export allows files outside the project root to be embedded in the generated package tarball. The file collection helpers (gleam_files, native_files, private_files) in compiler-cli/src/fs.rs use follow_links(true) when walking publishable directories such as src/ and priv/. The collected paths are added to the package archive via add_path_to_tar in compiler-cli/src/publish.rs without verifying that the resolved target remains within the project root. A symlink placed under a publishable directory will cause gleam export hex-tarball or gleam publish to embed the contents of the symlink target into the generated Hex package. An attacker with write access to the project repository can place a symlink in src/ or priv/ pointing to an arbitrary file. When a maintainer or CI pipeline runs gleam publish or gleam export hex-tarball, local files readable by the publisher (such as secrets, tokens, or SSH keys) are silently embedded into the published package artifact. This issue affects Gleam from 0.10.0-rc1 until 1.17.0.
Metrics
CVSS:4.0/AV:L/AC:L/AT:N/PR:L/UI:A/VC:H/VI:N/VA:N/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
Weakness Enumeration
References
Timeline
- Published
- Last Modified
- Status
- Deferred
Frequently Asked Questions
What is CVE-2026-42795?
How severe is CVE-2026-42795?
How do I fix CVE-2026-42795?
How Strix Helps
- How Strix found a critical auth bypass in etcdStrix autonomously discovered a critical authentication bypass in etcd, later designated CVE-2026-33413.
- Autonomous PentestingAI agents that find and validate exploitable vulnerabilities like this one across your applications.
- PR ReviewsPentest every pull request so vulnerable code is caught before it ships to production.
- AI Penetration TestingHow AI-driven penetration testing continuously covers your attack surface.
Related CVEs from 2026
- CVE-2026-4279The Bread & Butter plugin for WordPress is vulnerable to Sto…6.4
- CVE-2026-42790Improper Certificate Validation vulnerability in Erlang OTP …8.1
- CVE-2026-42791Improper Certificate Validation vulnerability in Erlang OTP …3.7
- CVE-2026-42792Improper Handling of Exceptional Conditions vulnerability in…7.5
- CVE-2026-42793Allocation of Resources Without Limits or Throttling vulnera…7.5
- CVE-2026-42794Improper Neutralization of Input During Web Page Generation …6.1
- CVE-2026-42796Arelle before 2.39.10 contains an unauthenticated remote cod…9.8
- CVE-2026-42797Exposure of Sensitive Information Through Data Queries vulne…4.9
- CVE-2026-42798Little CMS (lcms2) 2.16 through 2.18 before 2.19 has an inte…4
- CVE-2026-42799Out-of-bounds read vulnerability in ASR Kestrel (nr_fw modul…9.8
- CVE-2026-4280The Breaking News WP plugin for WordPress is vulnerable to L…6.5
- CVE-2026-42800NULL pointer dereference vulnerability in ASR1903 in ASR Lap…5.3
Are you affected by CVE-2026-42795?
Run a free Strix scan to check your systems for this vulnerability.
Scan your code nowSource: NVD / NIST
