Pages

Thursday, April 12, 2018

How to Connect to a SSH Server via Proxy

How to Connect to a  SSH Server via Proxy

While browsing, we can connect to internet either via direct connection or proxy connection.
Direct Connection, means you can directly access the Internet.
Proxy Connection, means you cannot directly access the internet, But can access via System which can reach Internet. Likewise, We can shall connect to a SSH Server via Proxy Server as well.

1. Install a Proxy Server [ http://blogforopensource.blogspot.com/2018/04/proxy-server-for-windows.html ]
2. Connect to SSH Server via this command.

 ssh USER@FINAL_DEST -o "ProxyCommand=nc -X connect -x PROXYHOST:PROXYPORT %h %p"

Requirement is that, we need to have the netcat [ nc ] command working . [ LINUX System ]

Direct Connection:

Proxy Connection:


Solution Reference:

https://stackoverflow.com/questions/19161960/connect-with-ssh-through-a-proxy

No comments:

Post a Comment