microsoft / microsoft/vscode

[Agents window] prompts for SSH key passphrase despite `PubkeyAuthentication no`

Open
#324,870 0 comments 0 reactions 0 assignees View on GitHub
Dominant language
TypeScript
Stars
193k
Forks
42.4k
PR merge metrics
PR metrics pending

Description

Does this issue occur when all extensions are disabled?: Yes/No

- VS Code Version: 1.127.0
- OS Version: Linux x64 7.0.13-1-MANJARO
Commit: 4fe60c8b1cdac1c4c174f2fb180d0d758272d713
Date: 2026-06-30T10:52:33+02:00
Electron: 42.2.0
ElectronBuildId: 14159160
Chromium: 148.0.7778.97
Node.js: 24.15.0
V8: 14.8.178.14-electron.0
- sshd: OpenSSH_10.0p2 Debian-7+deb13u4, OpenSSL 3.5.6 7 Apr 2026

Steps to Reproduce:
1. ~/.ssh/config host `vscode-2222` with `PubkeyAuthentication no` (below).
2. Terminal `ssh vscode-2222` → password prompt, no key offered. ✅
3. Remote-SSH (ms-vscode-remote.remote-ssh) connect → password prompt. ✅
4. Connect via [Agent feature] → prompts for **passphrase of the private key**. ❌

**Expected:** same as (2)/(3) — no key offered, straight to password.

**Actual:** passphrase prompt for [key path].

**Evidence:**
- `ssh -G vscode-2222 | grep -i pubkeyauth` → `pubkeyauthentication false`
- [Agent feature] runs:
```
2026-07-08 07:49:11.977 [info] [Shared] [SSHRemoteAgentHost] Connecting to ssh:vscode-2222
2026-07-08 07:49:11.983 [info] [Shared] [SSHRemoteAgentHost] Built 3 auth attempt(s): agent, publickey ~/.ssh/id_ed25519, keyboard-interactive
2026-07-08 07:49:11.985 [info] [Shared] Creating a socket (renderer-Tunnel-3170e0a4-1649-4bc6-90ef-f317f37460ca)...
2026-07-08 07:49:12.081 [info] [Shared] Creating a socket (renderer-Tunnel-3170e0a4-1649-4bc6-90ef-f317f37460ca) was successful after 95 ms.
2026-07-08 07:49:12.155 [info] [Shared] [SSHRemoteAgentHost] Trying auth: agent
2026-07-08 07:49:12.340 [info] [Shared] [SSHRemoteAgentHost] keyboard-interactive challenge from vscode-2222: 1 prompt(s)
2026-07-08 07:49:12.340 [info] [Shared] [SSHRemoteAgentHost] Trying auth: publickey ~/.ssh/id_ed25519
```

**Config:**
```
Host vscode-2222
HostName localhost
Port 2222
User vscode
PreferredAuthentications keyboard-interactive,password
PubkeyAuthentication no
```

Contributor guide

Open the contributing guide

Research direction

Start by tracing the SSHRemoteAgentHost authentication flow that builds the logged auth attempts, using the provided ssh config and reproduction steps. Compare the configured PreferredAuthentications and PubkeyAuthentication values with the agent, publickey, and keyboard-interactive attempts. Done means the Agent feature skips public-key authentication and does not prompt for the private-key passphrase in this configuration.

Written by the indexing model from the issue text.

Assessment

Tech stack
typescript
Domain
devtools
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Quiet
Clarity
Mostly clear
Newbie friendliness
55/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.