HIGH 7.8

CVE-2026-47292: Visual Studio Code Privilege Escalation Vulnerability

Visual Studio Code contains a flaw that allows an attacker with local access to run malicious code with elevated privileges. The vulnerability stems from the application loading or executing functionality from untrusted sources, which an attacker can exploit if they can trick a user into interacting with a malicious file or extension. This is a local privilege escalation risk that requires user interaction but poses a significant threat to developers and organizations relying on VS Code for secure development workflows.

Source data · NVD / CISA · public domain

CVSS
3.1 · 7.8 HIGH · CVSS:3.1/AV:L/AC:L/PR:N/UI:R/S:U/C:H/I:H/A:H
Weaknesses (CWE)
CWE-829, CWE-94
Affected products
1 configuration(s)
Published / Modified
2026-06-09 / 2026-06-17

NVD description (verbatim)

Inclusion of functionality from untrusted control sphere in Visual Studio Code allows an unauthorized attacker to elevate privileges locally.

1 reference(s) · View on NVD →

SEC.co analysis · AI-assisted, reviewed against source

Technical summary

CVE-2026-47292 involves the inclusion of functionality from an untrusted control sphere in Visual Studio Code, mapped to CWE-829 (Inclusion of Functionality from Untrusted Control Sphere) and CWE-94 (Improper Control of Generation of Code). The vulnerability has a CVSS 3.1 score of 7.8 (HIGH), with a local attack vector, low complexity, no privilege requirement, and user interaction needed. The attack results in complete compromise of confidentiality, integrity, and availability on the affected system. The flaw allows a local attacker to escalate privileges by executing untrusted code within the VS Code runtime, potentially via a malicious extension, untrusted workspace configuration, or crafted file that triggers automatic processing.

Business impact

For organizations using VS Code as their standard development environment, this vulnerability could enable insider threats or supply-chain attacks. An attacker gaining elevated privileges on a developer's machine could access sensitive source code repositories, exfiltrate credentials stored in the development environment, inject backdoors into software builds, or pivot laterally within corporate networks. The combination of user interaction and privilege escalation makes this particularly dangerous in shared development environments or when developers work with untrusted code repositories or third-party extensions.

Affected systems

Microsoft Visual Studio Code is the only affected product. All versions prior to the patch (verify against the official Microsoft security advisory for specific version numbers) are vulnerable. The risk applies to VS Code installations on Windows, macOS, and Linux systems where users have administrative or elevated permissions, or where the application runs with sufficient privilege to be exploited for further privilege escalation.

Exploitability

Exploitation requires local access and user interaction—an attacker must convince or trick a user into opening a malicious file, installing an untrusted extension, or cloning a repository with crafted configurations. The low complexity and lack of required prior privileges lower the bar for attackers with basic local system access. However, this is not an unauthenticated remote vulnerability; it does not spread via network propagation alone. The attack surface includes third-party extensions, workspace settings, and file associations that trigger VS Code automation.

Remediation

Microsoft has released patches to address this vulnerability. Users should update Visual Studio Code to the patched version immediately via the built-in update mechanism or by downloading the latest version from the official Microsoft website. Additionally, organizations should enforce policies restricting the installation of extensions to trusted sources, configure workspace trust settings to require explicit user approval for untrusted workspaces, and educate developers to avoid opening untrusted files or cloning code from unverified sources.

Patch guidance

Apply the latest available update for Visual Studio Code through the Help > Check for Updates menu (Windows/Linux) or Code > Check for Updates (macOS). Verify the patch version against the official Microsoft security advisory to confirm the specific build number that resolves CVE-2026-47292. For enterprise deployments, use centralized update management tools or software deployment systems to ensure all instances are patched. Test the update in a non-production environment first if your organization has critical development workflows dependent on VS Code stability.

Detection guidance

Monitor for unexpected VS Code process execution with elevated privileges, particularly child processes spawned from the IDE that access system files or registry. Log authentication events on shared development systems to detect unauthorized privilege escalation. Review VS Code extension installation logs and workspace configuration files for suspicious or newly added entries. Endpoint Detection and Response (EDR) tools should flag suspicious .code-workspace files or extension manifests that attempt to execute code outside the normal extension sandbox. Check for unsigned or malicious extensions installed within development environments.

Why prioritize this

While this vulnerability has a HIGH CVSS score (7.8) and requires user interaction, it is prioritized based on the critical role VS Code plays in modern software development. The privilege escalation component makes it attractive to sophisticated threat actors targeting development teams. The lack of current KEV (Known Exploited Vulnerability) status does not diminish urgency—organizations should assume active exploitation is possible and patch before adversaries develop reliable attacks. Development environments are high-value targets for supply-chain attacks, making this a business-critical remediation.

Risk score, explained

The CVSS 3.1 score of 7.8 reflects the severe impact (complete confidentiality, integrity, and availability compromise) combined with local attack vector and user interaction requirements. The score is elevated due to the unrestricted scope—an attacker gaining privilege elevation on a developer's machine effectively gains control over the system's security posture. However, the score is not critical (9.0+) because exploitation requires local access and user interaction, limiting opportunistic remote attacks. Organizations with strong endpoint security and user awareness training can reduce risk, but the underlying vulnerability severity remains high.

Frequently asked questions

Does this vulnerability affect VS Code running in containers or remote development scenarios?

Vulnerability exploitation depends on where code execution occurs. Remote SSH or container-based VS Code environments may have different privilege models, but if VS Code itself is running and accepts untrusted input (extensions, files), the risk remains. Verify your specific deployment architecture against the Microsoft advisory and isolate untrusted code execution environments with container security policies.

Are all VS Code extensions equally risky, or just third-party ones?

Third-party and community extensions from the Marketplace carry higher risk because Microsoft's vetting process is less rigorous than for built-in functionality. However, any extension—including official ones—can be compromised. Enable workspace trust prompts, review extension permissions, and use the VS Code extension deny-list policy to restrict installation to pre-approved extensions in sensitive environments.

Can this vulnerability be exploited without user interaction?

No. The vulnerability requires user interaction (opening a malicious file, installing an extension, or trusting a workspace). However, social engineering, supply-chain infiltration (compromised repositories), or auto-update mechanisms for extensions could minimize the barrier to triggering the vulnerability. Treat any untrusted code as a potential attack surface.

What is the current threat landscape for this CVE?

As of the publication and modification dates (June 2026), this CVE is not yet listed on CISA's KEV catalog, suggesting limited public exploitation at the time of disclosure. However, given the straightforward nature of the vulnerability and its high impact, assume sophisticated threat actors are actively developing exploits. Patch urgently rather than waiting for widespread active exploitation confirmation.

This analysis is based on publicly disclosed vulnerability information and the vendor's security advisory as of the publication date. Specific patch version numbers, affected component details, and remediation timelines should be verified directly against Microsoft's official security bulletin. SEC.co does not provide exploit code or detailed attack reproduction steps. Organizations should conduct their own risk assessment based on their specific VS Code deployment model, extension usage, and endpoint security posture. This explainer is intended to inform security decision-making and should not be considered legal advice or a substitute for vendor guidance. Source: NVD (public-domain), retrieved 2026-07-16. Analysis generated by SEC.co (claude-haiku-4-5).