Connect with SSH through a proxy

2019-03-07 17:19发布

I have no real idea what I'm doing here so please bear that in mind if you can help me!

I am trying to connect to my virtual server through a proxy but I can't connect, it just hangs. I'm assuming this is because it's not getting through our proxy.

I have tried exactly the same thing at home and it works perfectly. I'm on OSX running using Terminal to connect.

Can anyone advise me how I can get through the proxy with SSH?

8条回答
贼婆χ
2楼-- · 2019-03-07 18:20

I use -o "ProxyCommand=nc -X 5 -x proxyhost:proxyport %h %p" ssh option to connect through socks5 proxy on OSX.

查看更多
Deceive 欺骗
3楼-- · 2019-03-07 18:20
ProxyCommand nc -proxy xxx.com:8080 %h %p

remove -X connect and use -proxy instead.

Worked for me.

查看更多
登录 后发表回答