Skip to content

[3.0] Block the SSH tunnel when extensions.allowed forbids Remote - SSH - #2299

Merged
rclarey merged 3 commits into
release/3.xfrom
port-2290-to-3.x
Nov 12, 2026
Merged

rclarey merged 3 commits into
release/3.xfrom
port-2290-to-3.x

Conversation

@rclarey

@rclarey rclarey commented Nov 12, 2026

Copy link
Copy Markdown
Contributor

Changes

Port of #2290 to the 3.0 release branch

Starting a tunnel needs the host's Remote - SSH extension (ms-vscode-remote.remote-ssh, or anysphere.remote-ssh in Cursor). When the extensions.allowed policy blocks it, the connect fails late and confusingly. Check the setting up front and show a modal error with a shortcut to the setting instead.

The check follows VS Code's precedence: an extension ID rule beats a publisher rule (including the microsoft special case), which beats the * wildcard.

Tests

unit tests added

rclarey and others added 2 commits November 12, 2026 10:26
Port of #2290 to 3.x. Starting a tunnel needs the editor's Remote - SSH
extension (ms-vscode-remote.remote-ssh, or anysphere.remote-ssh in
Cursor). When the extensions.allowed policy blocks it, installing it
fails and the tunnel can't open its window. Check the setting before
installing Remote - SSH, signing in or picking compute, and fail with a
UserFacingError whose "Open setting" action opens extensions.allowed.

The check follows VS Code's precedence: an extension ID rule beats a
publisher rule (including the "microsoft" special case in VS Code),
which beats the "*" wildcard.

Co-authored-by: Isaac <no-reply@databricks.com>
…lues

Port of 0a7bd89 from #2290. Lowercase the setting's keys so lookups are
case-insensitive, as VS Code does, and treat null and arrays as
allow-all.

Co-authored-by: Isaac <no-reply@databricks.com>
The tunnel now reads extensions.allowed through kernel.settings, which
the test's hand-built kernel didn't have.

Co-authored-by: Isaac <no-reply@databricks.com>
@rclarey
rclarey merged commit 5fc1000 into release/3.x Nov 12, 2026
6 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants