CVE-2026-40090: CWE-22: Improper Limitation of a Pathname to a Restricted Directory ('Path Traversal') in zarf-dev zarf
Zarf versions 0. 23. 0 through 0. 74. 1 contain a path traversal vulnerability in the 'zarf package inspect sbom' and 'zarf package inspect documentation' subcommands. These subcommands construct output file paths by joining a user-controlled output directory with the package's Metadata. Name field, which can be manipulated by an attacker after unarchiving a package. This allows writing arbitrary files to locations on the filesystem accessible by the user running the command. The vulnerability is fixed in version 0. 74.
AI Analysis
Technical Summary
The vulnerability in zarf (versions 0.23.0 to 0.74.1) arises from improper limitation of a pathname to a restricted directory (CWE-22). The 'zarf package inspect sbom' and 'zarf package inspect documentation' subcommands create output file paths by concatenating a user-supplied output directory with the Metadata.Name field from the package's zarf.yaml manifest. Although Metadata.Name is initially validated against a regex during package creation, an attacker can modify this field after unarchiving the package to include path traversal sequences (e.g., '../../etc/cron.d/malicious') or absolute paths (e.g., '/home/user/.ssh/authorized_keys'). This manipulation enables arbitrary file writes with the permissions of the user running the inspect command. The issue was addressed and fixed in zarf version 0.74.2.
Potential Impact
An attacker who can supply or modify a zarf package can exploit this vulnerability to write arbitrary files to arbitrary locations on the filesystem where the inspect command is run. This can lead to unauthorized file modification or creation, potentially enabling further compromise depending on the files overwritten. The impact is limited to the permissions of the user executing the command. There are no known exploits in the wild as of the published date.
Mitigation Recommendations
This vulnerability is fixed in zarf version 0.74.2. Users should upgrade to version 0.74.2 or later to remediate this issue. Patch status is not explicitly stated in the vendor advisory, but the fix is included in the specified version. Until upgrading, avoid running the vulnerable subcommands on untrusted packages or in environments where arbitrary file writes could cause harm.
CVE-2026-40090: CWE-22: Improper Limitation of a Pathname to a Restricted Directory ('Path Traversal') in zarf-dev zarf
Description
Zarf versions 0. 23. 0 through 0. 74. 1 contain a path traversal vulnerability in the 'zarf package inspect sbom' and 'zarf package inspect documentation' subcommands. These subcommands construct output file paths by joining a user-controlled output directory with the package's Metadata. Name field, which can be manipulated by an attacker after unarchiving a package. This allows writing arbitrary files to locations on the filesystem accessible by the user running the command. The vulnerability is fixed in version 0. 74.
CVSS v3.1
Score 7.1high
Weaknesses
AI-Powered Analysis
Machine-generated threat intelligence
Technical Analysis
The vulnerability in zarf (versions 0.23.0 to 0.74.1) arises from improper limitation of a pathname to a restricted directory (CWE-22). The 'zarf package inspect sbom' and 'zarf package inspect documentation' subcommands create output file paths by concatenating a user-supplied output directory with the Metadata.Name field from the package's zarf.yaml manifest. Although Metadata.Name is initially validated against a regex during package creation, an attacker can modify this field after unarchiving the package to include path traversal sequences (e.g., '../../etc/cron.d/malicious') or absolute paths (e.g., '/home/user/.ssh/authorized_keys'). This manipulation enables arbitrary file writes with the permissions of the user running the inspect command. The issue was addressed and fixed in zarf version 0.74.2.
Potential Impact
An attacker who can supply or modify a zarf package can exploit this vulnerability to write arbitrary files to arbitrary locations on the filesystem where the inspect command is run. This can lead to unauthorized file modification or creation, potentially enabling further compromise depending on the files overwritten. The impact is limited to the permissions of the user executing the command. There are no known exploits in the wild as of the published date.
Mitigation Recommendations
This vulnerability is fixed in zarf version 0.74.2. Users should upgrade to version 0.74.2 or later to remediate this issue. Patch status is not explicitly stated in the vendor advisory, but the fix is included in the specified version. Until upgrading, avoid running the vulnerable subcommands on untrusted packages or in environments where arbitrary file writes could cause harm.
Technical Details
- Data Version
- 5.2
- Assigner Short Name
- GitHub_M
- Date Reserved
- 2026-04-09T00:39:12.206Z
- Cvss Version
- 3.1
- State
- PUBLISHED
- Remediation Level
- null
Threat ID: 69ded57682d89c981f20b4b0
Added to database: 4/15/2026, 12:01:58 AM
Last enriched: 4/22/2026, 6:45:13 AM
Last updated: 5/30/2026, 12:09:06 AM
Views: 61
Community Reviews
0 reviewsCrowdsource mitigation strategies, share intel context, and vote on the most helpful responses. Sign in to add your voice and help keep defenders ahead.
Want to contribute mitigation steps or threat intel context? Sign in or create an account to join the community discussion.
Actions
Updates to AI analysis require Pro Console access. Upgrade inside Console → Billing.
Need more coverage?
Upgrade to Pro Console for AI refresh and higher limits.
For incident response and remediation, OffSeq services can help resolve threats faster.
Latest Threats
Check if your credentials are on the dark web
Instant breach scanning across billions of leaked records. Free tier available.