CVE-2026-45772

Turborepo: Unexpected local code execution during Yarn Berry detection

Published May 15, 2026 CVSS 4.0 · 0 Low EPSS < 1% KEV · Not listed
Description
Turborepo is a high-performance build system for JavaScript and TypeScript codebases. From 1.1.0 to before 2.9.14, Turborepo can be vulnerable to arbitrary code execution when run in untrusted repositories that contain malicious Yarn configuration. In affected versions, package manager detection executed yarn --version from the project directory, which could cause Yarn to load and execute a project-controlled yarnPath from .yarnrc.yml. An attacker who controls repository contents could cause code execution when a user or CI system runs affected turbo, @turbo/codemod, or @turbo/workspace conversion commands. This vulnerability is fixed in 2.9.14.

Analysis

AI-generated

Technical impact

Turborepo builds JavaScript and TypeScript codebases, and between versions 1.1.0 and before 2.9.14 it can execute arbitrary code when a user or CI system runs turbo commands on a repository that contains a malicious .yarnrc.yml. During Yarn Berry detection the tool runs yarn --version from the project directory, which may trigger Yarn to load a project‐controlled yarnPath. An attacker who controls repository contents can place malicious code in the yarnPath and have it executed when turbo, @turbo/codemod, or @turbo/workspace conversion commands run. This flaw allows attackers to run code with the privileges of the user or CI job.

Affected Systems

The affected products are Turborepo by Vercel, with vulnerable releases from 1.1.0 up to (but not including) 2.9.14, as well as the related @turbo/codemod and @turbo/workspaces packages. Upgrade to 2.9.14 or later eliminates the flaw.

Risk and Exploitability

The flaw enables arbitrary code execution on the local system or within CI pipelines. The CVSS score of 9.8 indicates a critical severity, while the EPSS score of < 1% suggests a very low probability of exploitation. The vulnerability is not listed in CISA's KEV catalog. The likely attack vector involves an attacker placing a malicious repository that is later processed by a user or automated build via turbo. Because the vulnerability is triggered by Yarn Berry detection, it will be activated whenever those tools run on a repository containing a crafted .yarnrc.yml. In environments where untrusted code is routinely processed, the risk is significant.

Remediation

No solution or workaround provided in the CVE record.

OpenCVE Recommended Actions

  • Upgrade Turborepo, @turbo/codemod, and @turbo/workspaces to version 2.9.14 or later.
  • Restrict CI jobs to run turbo only against trusted repositories until the update is applied.
  • Validate repository contents or enforce a policy that blocks commits containing .yarnrc.yml with a yarnPath field from untrusted sources.

Generated by OpenCVE AI on May 19, 2026 at 16:07 UTC.

Tracking

Sign in to view the affected projects.

Advisories

Source ID Title
Github GHSA Github GHSA GHSA-3qcw-2rhx-2726 Turbo: Unexpected local code execution during Yarn Berry detection
History
Type Values Removed Values Added
CPEs cpe:2.3:a:vercel:turborepo:*:*:*:*:*:node.js:*:*
Metrics cvssV3_1

{'score': 9.8, 'vector': 'CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H'}

Type Values Removed Values Added
First Time appeared @turbo
@turbo codemod
@turbo workspaces
Vercel
Vercel turborepo
Vendors & Products @turbo
@turbo codemod
@turbo workspaces
Vercel
Vercel turborepo
Type Values Removed Values Added
Metrics ssvc

{'options': {'Automatable': 'yes', 'Exploitation': 'none', 'Technical Impact': 'partial'}, 'version': '2.0.3'}

Type Values Removed Values Added
Description Turborepo is a high-performance build system for JavaScript and TypeScript codebases. From 1.1.0 to before 2.9.14, Turborepo can be vulnerable to arbitrary code execution when run in untrusted repositories that contain malicious Yarn configuration. In affected versions, package manager detection executed yarn --version from the project directory, which could cause Yarn to load and execute a project-controlled yarnPath from .yarnrc.yml. An attacker who controls repository contents could cause code execution when a user or CI system runs affected turbo, @turbo/codemod, or @turbo/workspace conversion commands. This vulnerability is fixed in 2.9.14.
Title Turborepo: Unexpected local code execution during Yarn Berry detection
Weaknesses CWE-426
References
Metrics cvssV4_0

{'score': 0, 'vector': 'CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:N/VI:N/VA:N/SC:N/SI:N/SA:N'}

Weaknesses

Sources

Status
PUBLISHED
Assigner
GitHub_M
Published
Updated
May 15, 2026, 5:54 PM
Reserved
May 13, 2026, 7:45 AM
Status
Analyzed
Published
May 15, 2026, 4:16 PM
Modified
Oct 26, 2026, 2:10 PM