|JP Vossen on 23 Feb 2016 08:02:04 -0800|
[Date Prev] [Date Next] [Thread Prev] [Thread Next] [Date Index] [Thread Index]
|[PLUG] PuTTY ProxyCommand?|
Second, we forgot to announce dinner after, so some of the new folks may have missed that. Sorry...we usually go to a local restaurant after meetings. For PLUG W it's "The Office" which is more-or-less across the street from ATS.
Third, at dinner we were talking about the SSH ProxyCommand, and Jeff (IIRC) was wondering how to do that with PuTTY. I've been wondering that myself, I know how to chain proxies using OpenSSH '~/.ssh/config', e.g. to use jump hosts, but it's not clear how to do that using PuTTY, which I may not need again periodically. Anyone have any clues?
Come to think of it, "cool stuff to do with your SSH config" might be an interesting talk.
This is an untested example OpenSSH '~/.ssh/config' from Linux but it's adapted from stuff I'm really doing and works great. So this may not work 100% but should be enough for some useful clues. Note `ssh -vvvv` will display config file processing. Also note the "-W" for ProxyCommand was introduced in OpenSSH 5.4 so older versions (and a LOT of older docs on the Net) use `nc` (NetCat) instead. I find that amusing because the presence of NetCat used to make security auditors heads explode, so using it in SSH is rather ironic.
----- Host * ServerAliveInterval = 100 ForwardAgent yes # OpenSSH v4+ # http://www.torchbox.com/blog/ssh_tips_2.html# http://nion.modprobe.de/blog/archives/502-Speeding-up-SSH-ControlMaster.html
ControlPath ~/.ssh/master-%r@%h:%p ControlMaster auto ControlPersist 120 # Awesome wild-card shortcut to expand hostnames, except for jump hosts host *-site1 *-site2 !jh*-* HostName %h.example.com host jh01-site1 jh01-site1.example.com HostName 10.10.10.10 Port 4242 User fprefect IdentityFile ~/.ssh/ford_prefect ForwardAgent yes Compression yes host jh01-site2 jh01-site2.example.com HostName 10.10.20.10 Port 4242 User fprefect IdentityFile ~/.ssh/ford_prefect ForwardAgent yes Compression yes host someserver-site1 HostName 10.10.10.76 ProxyCommand ssh -A -W %h:%p jh01-site1.example.com host gateway-site3 HostName 10.10.10.76 ProxyCommand ssh -A -W %h:%p jh01-site1.example.com ## 2 levels: via GW3 via JH1 host someserver-site3 HostName 10.10.30.26 ProxyCommand ssh -A -W %h:%p gateway-site3.example.com ----- So...how do you do ProxyCommands and chaining in PuTTY? Later, JP -- ------------------------------------------------------------------- JP Vossen, CISSP | http://www.jpsdomain.org/ | http://bashcookbook.com/ ___________________________________________________________________________ Philadelphia Linux Users Group -- http://www.phillylinux.org Announcements - http://lists.phillylinux.org/mailman/listinfo/plug-announce General Discussion -- http://lists.phillylinux.org/mailman/listinfo/plug