Visual Studio Code Remote Code Execution Vulnerability (CVE-2026-41611)
Visual Studio Code fails to neutralise script-related HTML tags in a web page, a basic cross-site scripting flaw. An attacker who can get a user to trigger the payload in the application could execute code locally on that machine.
Originally disclosed on Microsoft
Description
Improper neutralization of script-related html tags in a web page (basic xss) in Visual Studio Code allows an unauthorized attacker to execute code locally.
FAQ
According to the CVSS metric, the attack vector is local (AV:L). Why does the CVE title indicate that this is a remote code execution? The word Remote in the title refers to the location of the attacker. This type of exploit is sometimes referred to as Arbitrary Code Execution (ACE). The attack itself is carried out locally. This means an attacker or victim needs to execute code from the local machine to exploit the vulnerability.
FAQ
According to the CVSS metric, user interaction is required (UI:R). What interaction would the user have to do? Exploitation of this vulnerability requires that a user trigger the payload in the application.
Visual Studio Code
Visual Studio Code
Microsoft
Microsoft
Customer Action Required
Yes
Not written yet. The AI write-up for this report has not been written yet. The Original tab links to the source.
How it worked
Root cause
Likely the editor renders web content without properly neutralising script-related HTML tags, allowing injected script to run.
Impact
An attacker could execute code locally, but only if the user triggers the payload in the application, so it is not exploitable without that interaction.
What the attacker needed
Victim triggers the payload in the app; attacker needs local access to run code
Explained by bugbounty.wiki with AI from the original and checked against quotes from it; it can still be wrong. Read the original before relying on a detail.
Not written yet. The AI write-up for this report has not been written yet. The Original tab links to the source.
Visual Studio Code is a popular code editor. It contains a flaw where it displays some web content without cleaning it first, so hidden script can slip through. If a user opens the malicious content, that script can run on their computer, which is why the vendor calls it code execution.
What is XSS?
Script an attacker supplies runs in another user's browser, on the target's origin, with that user's session.