VSCode's SSH Agent Is Bananas
Thomas Ptacek details how VSCode Remote SSH installs a persistent WebSocket agent with filesystem, file-editing, and shell access, resembling remote-access tooling.
A Fly.io blog post by Thomas Ptacek examines how VSCode's remote SSH editing works: it stages a Bash snippet that downloads a full agent including a bundled Node binary onto the remote host. The agent communicates with the VSCode frontend over a port-forwarded WebSockets connection and can browse the filesystem, edit arbitrary files, spawn shell PTY processes, and persist itself. Ptacek warns against allowing VSCode remote editing on shared dev servers or during production incidents, noting the design resembles remote-access tooling.
- VSCode Remote SSH runs a stager downloading a full agent with bundled Node binary.
- Agent connects via WebSockets over port-forwarded SSH to the frontend.
- Protocol can browse filesystem, edit files, launch shell PTYs, and persist.
- Author cautions against VSCode remote editing on shared dev or production systems.
- Organizations
- MicrosoftFly.ioThomas Ptacek
From the original article
2 min read at fly.io
We’re interested in getting integrated into the flow VSCode uses to do remote editing over SSH, because everybody is using VSCode now, and, in particular, they’re using forks of VSCode that generate code with LLMs. ”hallucination” is what we call it when LLMs get code wrong; “engineering” is what we call it when people do. LLM-generated code is useful in the general case if you know what you’re doing.
By Rapzid · fly.io
A short excerpt; the article and its images belong to the publisher. Summary, key facts and assessment above are AI-written from the article and can be wrong.