Skip to content
Access control Advisory Intermediate CVE-2019-1414

Visual Studio Code Elevation of Privilege Vulnerability (CVE-2019-1414)

Visual Studio Code exposed a debug listener to other users on the same local computer, and a local attacker who found the listening port could inject arbitrary code that ran with the current user's privileges. If that user had administrative rights, the attacker could take full control of the system.

Francesco Soncina Follow

Originally disclosed on Microsoft

Description

An elevation of privilege vulnerability exists in Visual Studio Code when it exposes a debug listener to users of a local computer. A local attacker who successfully exploited the vulnerability could inject arbitrary code to run in the context of the current user. If the current user is logged on with administrative user rights, an attacker could take control of the affected system. An attacker could then install programs; view, change, or delete data; or create new accounts with full user rights. To exploit this vulnerability, a local attacker would need to determine which port Visual Studio Code is listening on for a targeted user. The update address the vulnerability by modifying the way Visual Studio Code enables debug ports.

Visual Studio

Visual Studio

Microsoft

Microsoft

Customer Action Required

Yes

The original report as published on the Microsoft Security Response Center, by Francesco Soncina. Images and videos are our own copies; raw HTML is shown as text. View it on Microsoft Security Response Center.

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 debug listener was bound in a way that let other local users connect to it, rather than being restricted to the user who started the editor.

Impact

A local attacker could run arbitrary code as the current user, and if that user was an administrator, could take control of the affected system.

What the attacker needed

Local access to the same computer; another user logged into VS Code; attacker finds the debug port

The fix

The update was fixed by changing the way Visual Studio Code enables debug ports.

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 code editor. When it starts a debug listener, it opens a network port on the machine so a debugger can connect. The problem was that other users logged into the same computer could also reach that port, and through it make the editor run code as the person who owned the editor session.

What is Access control?

A user can do something their role should not allow: reach an admin function, act on a feature they have not paid for, or skip a permission check. IDOR is the special case where the object belongs to someone else.

More from Microsoft

View all

The newest disclosed reports for this program.

Similar reports

View all

Same bug class and techniques, clearest first.

Broken access control

The lesson behind this report.

A user can do something their role should not allow: reach an admin function, act on a feature they have not paid for, or skip a permission check. IDOR is the special case where the object belongs to someone else.