r/learnmachinelearning • • 19d ago

Request ChatGPT Desktop forwards your SSH agent to remote machines

A disclosure confirmed that a popular AI desktop application silently forwards the user's SSH agent to remote machines during sessions.

What this means in practice: every server your SSH key can reach becomes reachable through the AI session. The credential never leaves your device in the traditional sense. But the socket does. Any process the AI spawns can authenticate to your infrastructure as you, against hosts you never explicitly authorized, for the duration of that session.

This is not a hypothetical. The forwarding behavior was confirmed and documented. The scope of exposure scales directly with how permissive your SSH key is — a key that reaches prod reaches prod through the AI too.

The broader problem this surfaces: non-human software acting on your behalf does not respect the implicit mental model you have of what it is allowed to touch. The user thinks the AI is local. The SSH socket disagrees.

For those running AI tooling in environments where SSH keys have meaningful blast radius — how are you actually handling this? Are you scoping keys specifically for AI sessions, running AI tooling in isolated VMs, something else entirely? Curious what real mitigations look like in practice, not in theory.

0 Upvotes

3 comments sorted by

1

u/geofabnz 19d ago

This kind of stuff is why I’m paranoid… AI coding CLI’s and Production SSH can never live on the same machine. AI coding agents act as the user and this fundamentally breaks the SSH model. Multifactor SSH CA is a great tool but a lot of legacy systems don’t support it.

I keep my coding agents on a separate machine. I have a dedicated proxmox box for my agents. Openshell is great but it’s still only one part of a defense in depth solution.

0

u/No-Conclusion3720 19d ago

That isolation setup is the right instinct and honestly more rigorous than most teams bother with. Air-gapping the agent box from anything with prod SSH keys removes an entire class of problem before it starts, and you're right that CA-based SSH with MFA doesn't help if half your fleet is legacy and can't speak it.

Where RuntimeAI fits is a narrower slice than what you're describing: we're not a substitute for that network-level separation, we're for the case where the agent still needs to act as a credentialed identity to do its job (calling internal APIs, hitting a database, whatever), and you can't just wall it off because that's the point of running it. Flow Enforcer watches the actual call pattern at runtime, not just whether the key presented is valid, so if an agent process starts issuing requests outside its established behavioral baseline we can revoke that session's access in place rather than relying on the credential itself being well-scoped. It doesn't solve the SSH-forwarding problem you're pointing at, that's exactly the kind of thing a separate proxmox box for agents solves better than any runtime control can. It's meant for the layer after that, once something does have legitimate access and you need to catch it acting wrong.

1

u/geofabnz 19d ago

Yes, it’s a problem that requires defence in depth to solve. My focus is on the higher level - what happens when all the rules fail, the agent escapes and is acting maliciously but your ruleset would come before that. One issue for me working in security is how do I know how the rules are actually enforced if I can’t see the code?

That’s one of the strongest aspects of openshell - it’s open source so I can see how the rules work without having to trust docs