通过 http 代理建立 SSH 隧道,并阻止 443(SSL)

通过 http 代理建立 SSH 隧道,并阻止 443(SSL)

当 https 访问被拒绝时,是否可以通过 http 代理创建 SSH 隧道?

我在 .ssh\config 中有这样的配置

Host home
User root
Hostname *my-home-pc-with-ssh-access-allowed*
Port 8090
ProxyCommand corkscrew db-isa-01 8080 %h %p ~/.ssh/.corkscrew-db-isa-auth
IdentityFile ~/.ssh/id_rsa

其中 db-isa-01 是我的公司代理服务器。今天管理员阻止了所有 https 访问,只允许白名单上的少数服务器访问。

我使用这个命令创建了一个隧道:

ssh -D 7070 -o 'GatewayPorts yes' -A -q -g -t  root@home

现在它不起作用了。据我所知,那是因为我们的代理拒绝所有 https 连接

Proxy could not open connnection to ***:  Proxy Error ( The specified
Secure Sockets Layer (SSL) port is not allowed. Forefront TMG is not configured to 
allow SSL requests from this port. Most Web browsers use port 443 for SSL requests.  )

PS 我使用 Windows 7 和带有 cygwin 的 corscskrew,因此 Linux 解决方案不适合我。

答案1

您可以关注本指南并使用http隧道在 HTTP 请求中建立 SSH 连接隧道。Win32 二进制文件可用这里

相关内容