SSH port forwarding through Windows machine

sshssh-tunneltunneling

is it possible to connect to an SSH server only accessible from inside a network, using a Windows machine without SSH as a gateway?.

Let me clarify my question with a sketch:

Me (Linux machine)—> WIN (Windows without SSHD)—>LIN (Linux with SSHD).

Machine Me, is the PC I'm using to connect to LIN through WIN. WIN is accessible from the outside, it has an RDESKTOP port open, and LIN is only accessible from inside the network.

Hope you understand the question.

Best Answer

OpenSSH has a very flexible ability to use proxy via the ProxyCommand option. If the Windows box doesn't have an SSH daemon on it, then can you install a socks proxy, an HTTP CONNECT proxy, or a generic TCP proxy? If so, then you can use it as a point to connect to the internal system. The exact details would depend on exactly what kind of proxy you install, and what kind of firewalls/filters are between the various systems.

There is no way you are going to do this without installing at least some kind of proxy on the Windows box. Windows doesn't have any built-in generic proxy that would allow it to forward SSH traffic.