Summary
A security feature bypass vulnerability exists in VS Code 1.141.0 and earlier versions where relaunching or reusing an integrated terminal did not apply the Workspace Trust check that runs when a terminal is first created. In a workspace open in Restricted Mode, this could allow a local terminal process to start even though Workspace Trust blocks creating a new terminal.
Details
An attacker would need to convince the user to open a malicious workspace and interact with it.
Patches
The fix is available starting with VS Code 1.141.1. The fix (1c89ae4) mitigates this by running the same Workspace Trust check before a terminal process is relaunched or reused.
Workarounds
Do not open untrusted workspaces. If an untrusted workspace is already open, do not launch or relaunch an integrated terminal.
References
Summary
A security feature bypass vulnerability exists in VS Code 1.141.0 and earlier versions where relaunching or reusing an integrated terminal did not apply the Workspace Trust check that runs when a terminal is first created. In a workspace open in Restricted Mode, this could allow a local terminal process to start even though Workspace Trust blocks creating a new terminal.
Details
An attacker would need to convince the user to open a malicious workspace and interact with it.
Patches
The fix is available starting with VS Code 1.141.1. The fix (1c89ae4) mitigates this by running the same Workspace Trust check before a terminal process is relaunched or reused.
Workarounds
Do not open untrusted workspaces. If an untrusted workspace is already open, do not launch or relaunch an integrated terminal.
References