4 ms·
My big worry with ssh-agent forwarding is that someone may get root on a random server I connect to and then be able to use my forwarded connection to access an
by IgorPartola 12y ago
My big worry with ssh-agent forwarding is that someone may get root on a random server I connect to and then be able to use my forwarded connection to access another machine. To avoid this I created https://github.com/ipartola/mac-ssh-confirm https://github.com/ipartola/mac-ssh-confirm. Basically, every time you go to use your ssh-agent you get a GUI confirmation dialog with OK/Cancel. That way you can prevent unauthorized access.
- keeperofdakeys 12y agossh-add (at least on linux) has the -c option, which tells ssh-agent to do exactly this.
- IgorPartola 12y agoThat's what I use. ssh-add properly does not actually include a UI of any kind. It just calls $SSH_ASKPASS. The linked code essentially provides two wrappers around all this: one to add keys and set up SSH_ASKPASS, and the other to be the script that is $SSH_ASKPASS that uses the Mac OS X GUI to show you the confirmation dialog.