CVEReports
CVEReports

Automated vulnerability intelligence platform. Comprehensive reports for high-severity CVEs generated by AI.

Product

  • Home
  • Sitemap
  • RSS Feed

Company

  • About
  • Contact
  • Privacy Policy
  • Terms of Service

© 2026 CVEReports. All rights reserved.

Made with love by Amit Schendel & Alon Barad



CVE-2026-29064

CVE-2026-29064: Path Traversal via Symlink Extraction in Zarf

Alon Barad
Alon Barad
Software Engineer

Mar 6, 2026·6 min read·74 visits

Executive Summary (TL;DR)

Zarf versions prior to 0.73.1 fail to validate symbolic link targets during archive extraction. Attackers can craft malicious packages containing symlinks that point to arbitrary locations on the host filesystem (e.g., /etc/shadow), leading to arbitrary file read or write access when the package is decompressed.

A high-severity path traversal vulnerability exists in the archive extraction component of Zarf, an airgap-native Kubernetes package manager. The flaw allows malicious packages to write files outside the intended extraction directory via unvalidated symbolic links. This vulnerability affects Zarf versions 0.54.0 through 0.73.0 and is remediated in version 0.73.1.

Vulnerability Overview

Zarf is a CLI tool used to package, ship, and deploy Kubernetes clusters and applications in air-gapped environments. A core function of Zarf is the archiver component, which handles the compression and decompression of package artifacts (typically tarballs or zip files). CVE-2026-29064 identifies a critical flaw in how this component handles symbolic links during the extraction process.

The vulnerability is a variation of the "Zip Slip" class of path traversal issues. When Zarf extracts an archive, it processes file entries sequentially. If an entry is a symbolic link, Zarf creates it on the filesystem. However, in affected versions, the extraction logic does not properly sanitize or restrict the LinkTarget of these symlinks. This allows a malicious archive to create a symlink that points to a sensitive location on the host system (e.g., /etc/shadow or ~/.ssh/authorized_keys) rather than a file within the extraction sandbox.

While the creation of the symlink itself might be benign, subsequent operations—such as writing to a file that resolves through that symlink—can result in arbitrary file overwrites. Furthermore, if the user or a downstream process interacts with the extracted directory, they may unwittingly access or modify sensitive host files.

Root Cause Analysis

The root cause lies in the implementation of the defaultHandler, stripHandler, and filterHandler functions within src/pkg/archive/archive.go. These handlers are responsible for iterating through archive headers and performing filesystem operations based on the entry type.

In the vulnerable code, when a handler encounters a symbolic link (Type Symlink), it extracts the LinkTarget string from the archive header and passes it directly to os.Symlink. While the destination path (dst) is often constructed using filepath.Join, this function only performs lexical cleaning (e.g., removing .. references within the path string) but does not resolve the physical path or validate that the symlink target resides within the intended directory tree.

Specifically, the code lacked a "jail check"—a mechanism to resolve the canonical path of the symbolic link's target and verify it starts with the canonical path of the extraction root. Without this check, a LinkTarget of ../../../../etc/passwd is accepted as valid. When the operating system processes the symlink() syscall, it creates a link on the filesystem that points outside the extraction root, effectively bypassing the application's intended sandbox.

Code Analysis & Fix

The remediation for this vulnerability leverages the os.Root API introduced in Go 1.24, which provides a robust mechanism for directory-scoped file operations. This approach is superior to traditional string-based sanitization as it enforces boundaries at the file descriptor level.

Vulnerable Logic (Simplified): The original code relied on standard os package calls that operate on global paths. Note the lack of validation on h.Linkname.

// BEFORE: src/pkg/archive/archive.go
func (h *defaultHandler) Handle(ctx context.Context, header *tar.Header, dst string) error {
    target := filepath.Join(dst, header.Name)
    // ...
    case tar.TypeSymlink:
        // Vulnerability: h.Linkname is trusted blindly
        if err := os.Symlink(header.Linkname, target); err != nil {
            return err
        }
    // ...
}

Patched Logic: The fix, applied in commit 93f9c33, refactors the extraction to use an os.Root handle. The extraction root is opened once, and all subsequent operations (creating directories, opening files, creating symlinks) are performed relative to this root handle using the root object methods. The OS kernel ensures these operations cannot escape the directory descriptor.

// AFTER: src/pkg/archive/archive.go
func (h *defaultHandler) Handle(ctx context.Context, root *os.Root, header *tar.Header) error {
    // 1. Sanitize entry name to prevent absolute paths or drive letters
    if err := validateEntryName(header.Name); err != nil {
        return err
    }
 
    // 2. Use root-scoped methods for filesystem operations
    switch header.Typeflag {
    case tar.TypeSymlink:
        // 3. Additional validation on the symlink target
        if err := validateSymlink(header.Linkname); err != nil {
            return err
        }
        // 4. Create symlink relative to the root handle
        // The 'root' object enforces the sandbox boundary
        if err := root.Symlink(header.Linkname, header.Name); err != nil {
            return err
        }
    }
}

Exploitation Methodology

Exploiting this vulnerability requires the attacker to create a specially crafted archive (TAR or ZIP) and convince a user to extract it using the zarf tools archiver decompress command. The attack does not require authentication to the system but does require the ability to supply the malicious package.

Step-by-Step Recreation:

  1. Preparation: The attacker identifies a target file on the victim's system (e.g., /etc/shadow or a sensitive configuration file).
  2. Archive Creation: The attacker creates a symlink on their local machine pointing to the target file using relative paths.
    ln -s ../../../../../etc/shadow malicious_link
  3. Packaging: This symlink is packaged into a tarball. Standard tar commands preserve the relative link target.
    tar -czf exploit.tar.gz malicious_link
  4. Delivery & Execution: The attacker distributes exploit.tar.gz. When the victim runs zarf tools archiver decompress exploit.tar.gz output_dir, Zarf replicates the symlink in output_dir.
  5. Impact Realization: The resulting file output_dir/malicious_link now points to /etc/shadow. If the victim (or a script) reads from this file, they read the shadow file. If the archive contained a second entry that wrote data to malicious_link, the extraction process itself would overwrite /etc/shadow.

Impact Assessment

The successful exploitation of CVE-2026-29064 results in a high-impact integrity and confidentiality breach. The specific impact depends on the context in which Zarf is running.

Scenario 1: CI/CD Pipelines Zarf is frequently used in automated pipelines to prepare air-gapped bundles. If a pipeline extracts a malicious package, the attacker could overwrite pipeline configuration files, inject backdoors into build artifacts, or exfiltrate secrets available on the build agent's filesystem.

Scenario 2: Developer Workstations Developers using Zarf to examine packages locally run the tool with their user privileges. An attacker could overwrite ~/.ssh/authorized_keys to gain persistent access or read ~/.aws/credentials.

CVSS Breakdown (8.2): The vulnerability scores High because the scope is Changed (S:C)—the attack impacts the underlying host operating system, not just the Zarf application. Integrity (I:H) and Confidentiality (C:H) are both rated High due to the potential for arbitrary file access. User Interaction (UI:R) is required, preventing a 9.0+ score.

Official Patches

ZarfCommit fixing the vulnerability using os.Root
ZarfZarf v0.73.1 Release Notes

Fix Analysis (1)

Technical Appendix

CVSS Score
8.2/ 10
CVSS:3.1/AV:L/AC:L/PR:N/UI:R/S:C/C:H/I:H/A:N
EPSS Probability
0.04%

Affected Systems

Zarf CLI < 0.73.1

Affected Versions Detail

Product
Affected Versions
Fixed Version
Zarf
Defense Unicorns
>= 0.54.0, < 0.73.10.73.1
AttributeDetail
CVE IDCVE-2026-29064
CVSS v3.18.2 (High)
CWE IDCWE-22
Attack VectorLocal / User Interaction
ImpactArbitrary File Read/Write
Affected Versions0.54.0 - 0.73.0

MITRE ATT&CK Mapping

T1083File and Directory Discovery
Discovery
T1005Data from Local System
Collection
CWE-22
Improper Limitation of a Pathname to a Restricted Directory ('Path Traversal')

Vulnerability Timeline

Fix commit merged
2026-03-03
Zarf v0.73.1 Released
2026-03-03
CVE and GHSA Advisory Published
2026-03-06

References & Sources

  • [1]GHSA-hcm4-6hpj-vghm Advisory
  • [2]NVD - CVE-2026-29064

More Reports

•31 minutes ago•GHSA-456V-XQ2P-R4CJ
7.8

GHSA-456V-XQ2P-R4CJ: OS Command Injection in code-ollama grep_search Tool

An OS command injection vulnerability in the grep_search tool of the code-ollama package allows remote code execution. This vulnerability is triggered when a local client executes the CLI against a malicious or compromised Ollama server. Due to grep_search being classified as a read-only tool, the CLI executes it automatically in Plan mode without human-in-the-loop validation, leading to zero-interaction local system compromise.

Amit Schendel
Amit Schendel
2 views•5 min read
•41 minutes ago•CVE-2026-76460
10.0

CVE-2026-76460: Cisco Identity Services Engine Authentication Bypass Vulnerability

On September 16, 2026, Cisco disclosed a critical authentication bypass vulnerability affecting Cisco Identity Services Engine (ISE) and Cisco ISE Passive Identity Connector (ISE-PIC). This vulnerability allows unauthenticated, remote attackers to bypass the administrative interface controls and execute privileged API requests. Due to active exploitation in the wild, the Cybersecurity and Infrastructure Security Agency (CISA) added this vulnerability to the Known Exploited Vulnerabilities (KEV) Catalog with an immediate remediation deadline.

Alon Barad
Alon Barad
5 views•4 min read
•2 days ago•CVE-2026-53493
6.9

CVE-2026-53493: Uncontrolled Resource Consumption in containerd Image-Pull Descriptor Graph Resolution

containerd is an open-source container runtime. Prior to versions 1.7.36, 2.0.13, 2.2.9, 2.3.6, and 2.4.1, a crafted OCI index graph can force very high CPU/memory usage during PullImage (before container start), causing long ContainerCreating stalls and, at larger sizes, node/runtime instability. The vulnerability occurs because containerd's image-pull descriptor graph resolution handlers processed OCI image indices and manifests recursively without enforcing boundaries on traversal depth or breadth, and without maintaining a global visited registry to count duplicate references.

Alon Barad
Alon Barad
34 views•6 min read
•2 days ago•GHSA-62MM-XWMV-CRHG
7.5

GHSA-62MM-XWMV-CRHG: Unauthenticated Path Traversal in Khoj Static File Serving Endpoint

An unauthenticated path traversal vulnerability exists in the Khoj AI assistant platform via the static file serving endpoint `/home/{file_path:path}`. Due to improper path sanitization when handling user input with Python's pathlib module, a remote attacker can read arbitrary files from the server's filesystem.

Alon Barad
Alon Barad
13 views•5 min read
•2 days ago•CVE-2026-100369
8.4

CVE-2026-100369: Argument Injection Vulnerability in CliInvoke Process Runner Factories

An argument injection vulnerability (CWE-88) in CliInvoke and AlastairLundy.CliInvoke allows local attackers to execute arbitrary system commands. By injecting double-quote characters into target file paths or arguments, attackers can terminate operating-system-level quoted boundaries and introduce new commands when shell runners are utilized.

Amit Schendel
Amit Schendel
10 views•5 min read
•2 days ago•CVE-2026-100368
8.4

CVE-2026-100368: OS Command Injection in CliInvoke Shell Wrappers

An OS command injection vulnerability exists in the PowerShell and Cmd shell wrappers of the CliInvoke .NET library (specifically the CliInvoke.Specializations package). Under vulnerable configurations, arguments and targets are passed as a single flat string to ProcessStartInfo.Arguments, permitting double-quote breakout and execution of arbitrary secondary commands with host process privileges.

Amit Schendel
Amit Schendel
10 views•7 min read