External risk intelligence

PyVista Dependency Confusion Leading to Remote Code Execution.

CVE advisorySeverity: CRITICAL (CVSS 9.3)

CVE-2025-61774

This vulnerability is a dependency confusion issue occurring within build scripts and Dockerfiles used for development and environment setup. Such tasks are typically performed in isolated, internal build-time environments or by developers, rather than being components of a public-facing service or internet-exposed application.

Code Injection

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

This CVE identifies a critical vulnerability in the PyVista project, a tool for 3D plotting and mesh analysis, related to how it manages software dependencies. The issue could allow malicious code to be introduced during the build process, potentially impacting the integrity of the software supply chain. As a patched version is currently unavailable, the primary concern is to determine if this specific dependency management practice is utilized within the organization's development environments.

  • Dependency confusion in build process.
  • Confirms potential software supply chain risk.
  • Assess relevance to internal build pipelines.

Attack Path

How an attacker could exploit the issue

An attacker could exploit this vulnerability by publishing a malicious package to a public Python index (PyPI) with a higher version number than a package intended for internal use. When the vulnerable software, specifically PyVista, attempts to install its dependencies using `pip` with an `--extra-index-url`, `pip` prioritizes the public index. If the attacker's package is downloaded, it can lead to remote code execution on the build system, enabling a supply chain attack.

  • Entry condition: Public package index available.
  • Trigger point: Dependency installation with `--extra-index-url`.
  • Resulting risk: Remote code execution and supply chain compromise.

Live Threat

Current exploitation, exposure, and threat context

This vulnerability could allow an attacker to execute arbitrary code on a system when it installs a specific package. This risk exists when the package manager, pip, is configured to use an external package index and an attacker publishes a malicious package with a higher version number on the public Python Package Index (PyPI) than a package intended to be fetched from the external index.

  • Malicious code execution.
  • Supply chain attack via dependency confusion.
  • Compromised system integrity.

Operational Fix

Recommended remediation, mitigation, and detection steps

This vulnerability resides in development or build-time dependencies, suggesting that application or platform teams responsible for managing build environments and developer tooling are the most likely owners. The immediate priority is to identify all internal or external build processes and CI/CD pipelines that utilize PyPI and custom package indexes, confirming if any are configured to use `--extra-index-url` with packages that might be susceptible to dependency confusion.

  • Identify build pipeline ownership.
  • Verify package index configurations.
  • Mitigate via dependency management.

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 PyVista project?

PyVista is a Python library used by researchers, engineers, and scientists for 3D plotting and mesh analysis. It provides a user-friendly interface for the Visualization Toolkit (VTK), which is a powerful engine for processing and rendering complex 3D data. People use PyVista to visualize volumetric datasets and perform geometric analysis in environments like Jupyter notebooks or custom desktop applications.

What does CWE-94 mean in the context of CVE-2025-61774?

CWE-94 refers to improper control of generation of code, often called code injection. In this CVE, it describes a flaw where the software can be tricked into downloading and executing malicious code. This happens because the installer prioritizes public software repositories over intended private ones, allowing an attacker to inject their own malicious package into the build process.

How does an attacker trigger this vulnerability?

An attacker triggers this by publishing a malicious package to the public Python Package Index (PyPI) with a higher version number than a package the project expects to pull from a private source. The bug is triggered during the dependency installation phase when the `--extra-index-url` flag is used. It is not triggered if the environment only uses verified local package caches or explicitly pinned dependencies without these index flags.

Is this vulnerability relevant to my internet-facing web apps?

According to Halo Surface Signal, this vulnerability is very unlikely to affect public-facing web services. The flaw exists specifically within build scripts and Dockerfiles used for development or environment setup. It is a supply chain risk primarily for internal build-time environments where automated dependency installation occurs, rather than a bug within the application's runtime code.

What should I do if I use PyVista in my build environment?

You should audit your CI/CD pipelines and developer Dockerfiles to find where `--extra-index-url` is used for installing dependencies. Since a patch is not yet available, focus on isolating build processes or manually verifying that all required dependencies are present in your trusted repositories to prevent the installer from reaching out to public indexes for missing packages.

References