External risk intelligence

fastcore untar_dir Path Traversal Vulnerability

CVE advisorySeverity: CRITICAL (CVSS 9.2)

CVE-2026-65320

The vulnerability exists in a software library (fastcore) within a specific helper function for archive extraction. This is a developer-centric utility used within application code rather than a standalone, internet-facing service or appliance. Public network exposure is not a standard characteristic of this library, and exploitation requires the application to be specifically processing untrusted user-supplied archives.

Path Traversal

Halo Surface Signal: 1 out of 5 — much less likely to be public-facing.

External exposure likelihood

Horizon Alert

Summary of the vulnerability and why it matters

A path traversal vulnerability exists in the `fastcore.xtras.untar_dir()` function, which can allow an attacker to write files to arbitrary locations on a system by providing a specially crafted tar archive. This could potentially lead to code execution, data modification, or denial of service if applications process untrusted archives using this function.

  • Malicious archives can overwrite important files.
  • Affects applications processing untrusted archives.
  • Confirm relevance and check for exposure.

Attack Path

How an attacker could exploit the issue

An attacker could exploit this vulnerability by tricking an application into extracting a specially crafted tar archive. The application, using a vulnerable function, would then write files to arbitrary locations on the system instead of the intended directory. This could lead to the modification or replacement of critical application files or even allow arbitrary code execution.

  • Requires processing untrusted archives.
  • Exploits archive extraction function.
  • Enables arbitrary file writes.

Live Threat

Current exploitation, exposure, and threat context

A path traversal vulnerability in the `fastcore.xtras.untar_dir()` function could allow an attacker to write files to arbitrary locations on the system if an application processes a crafted tar archive. This could affect application files, configuration, or importable code, potentially leading to code execution, data modification, or denial of service when running on Python versions before 3.14.

  • Application files and code are at risk.
  • A crafted tar archive can overwrite files.
  • Arbitrary file writes could lead to code execution.

Operational Fix

Recommended remediation, mitigation, and detection steps

Applications utilizing the `fastcore.xtras.untar_dir()` function to extract untrusted archives are at risk from this path traversal vulnerability. The first practical step is to identify all instances of this function, determine which handle untrusted input, and assess their business criticality and exposure. Accountable teams, likely application owners or development teams, should then coordinate remediation efforts based on this risk assessment.

  • Application owners should own this issue.
  • Verify untrusted archive extraction points.
  • Plan remediation based on assessed risk.

Supplementary metadata

Validate whether this threat affects your internet-facing exposure.

Halo Threat Intelligence helps prioritize remediation with Halo Surface Signal and H/A/L/O context. Start exposure validation with a free external attack surface trial.

Frequently asked questions

What is the fastcore library?

fastcore is a Python library that provides a set of extensions for the Python language, often used by data scientists and developers to simplify complex coding tasks. It acts as a foundational toolkit to improve productivity by adding functionality for high-level operations. CVE-2026-65320 specifically affects a utility within this library, fastcore.xtras.untar_dir(), which is designed to handle the extraction of archive files.

How does CVE-2026-65320 create a path traversal risk?

This vulnerability is classified as CWE-22, or Path Traversal. It occurs because the library's extraction helper does not properly check the contents of a tar archive for malicious paths. When an application uses this function to extract a crafted file, the software fails to contain the files within the target folder. Instead, it allows the archive to write data to arbitrary locations on the host system by using sequence paths like '../' to escape the intended directory.

When does this vulnerability trigger?

The flaw triggers only when an application specifically uses the untar_dir() function to process an untrusted tar archive supplied by an attacker. It is not triggered by simply installing the library. Furthermore, the vulnerability is tied to the underlying Python environment; if the application is running on Python 3.14 or newer, the platform's native improvements to archive extraction may prevent this specific path traversal behavior.

Is my application at risk according to Halo Surface Signal?

Halo Surface Signal indicates that risk is very unlikely for most systems because fastcore is a developer library, not an internet-facing service. The vulnerability only becomes a concern if your application is configured to accept and extract archive files from untrusted users. If your code does not process external, user-provided archives, the likelihood of exploitation is significantly reduced.

What should I do if my code uses fastcore?

First, search your codebase to identify every instance where untar_dir() is called. Once mapped, determine if any of these instances handle archives uploaded or supplied by users. If they do, prioritize these points for review. Work with your development team to replace the function with a more secure alternative or to implement strict path validation before extraction, as this will mitigate the risk of arbitrary file overwrites.

References