How can I establish a reverse ssh tunnel with my ./ssh/config file?
I'm trying to reproduce this command
ssh [email protected] -L 4444:restricedserver1.org:4420 -L 4445:restricedserver2:4430
Unix & Linux Stack Exchange is a question and answer site for users of Linux, FreeBSD and other Un*x-like operating systems. It only takes a minute to sign up.Sign up to join this community
You don't need a tunnel. Use
Host restricedserver1 HostName restricedserver1.org User admin Port 4420 ProxyCommand ssh -A -q -l %r -W %h:4444 dmx.com ControlMaster auto ControlPersist 5m
and similar for the other host. The advantage over a tunnel is that you don't need to keep it up all the time.