Amazon Linux with OpenSSH 6.6.1, OpenSSL 1.0.1k-fips 8 Jan 2015 Win 10 with Cygwin OpenSSH 7.3p1, OpenSSL 1.0.2h 3 May 2016 我可以交互ssh没有问题:
win10$ ssh [email protected] aws$
这个端口转发也可以工作:
win10$ ssh -NTL 9003:localhost:80 [email protected] & win10$
我使用后者通过访问服务器上的phpmyadmin:
http://phpmyadmin.localhost:9003
这工作正常。
为了使用netbeans来debugging运行在服务器上的php代码,我这样做:
win10$ ssh -NTR 9000:localhost:9000 [email protected] &
这用于工作没关系。 但升级Cygwin后,我现在得到:
ssh: connect to host example.com port 22: Operation not permitted
在命令行中添加-vvvv并不能提供更多的信息:
win10$ ssh -vvvv -NTR 9000:localhost:9000 [email protected] OpenSSH_7.3p1, OpenSSL 1.0.2h 3 May 2016 debug1: Reading configuration data /home/user/.ssh/config debug2: resolving "example.com" port 22 debug2: ssh_connect_direct: needpriv 0 debug1: Connecting to example.com [nn.nn.nn.nn] port 22. debug1: connect to address nn.nn.nn.nn port 22: Operation not permitted ssh: connect to host example.com port 22: Operation not permitted
我相信,以前的版本的ssh,我这样做是Cygwin on WinXP with OpenSSH 7.1p2, OpenSSL 1.0.2f, 28 Jan 2016
服务器上没有任何改变。 由于端口9000没有特权,我不认为这应该是一个权限问题,尤其是因为服务器configuration没有改变,但我不得不承认,端口转发对我来说基本上是魔术。 任何想法可能是错误的或如何收集更多/更好的信息?
这不是一个答案,这正是我所观察到的。 我重新启动了我的Win10电脑,它应用了一些正在等待的更新。 我还安装了Eset Internet Security,防火墙过滤模式设置为交互式。 重启后,当我尝试了以前失败的转发,Eset提示ssh.exe已被修改,并问是否可以保持规则允许它启动stream量。 我说没关系,然后又开始工作了。 在重新启动之前,Eset没有投诉。 如上所述,端口9003的转发工作正常。
我不知道这是一个怎样的学习体验,除了Windows XP的“运行Windows Update,频繁重启”这个日常的Windows口头禅之外,现在这个问题已经解决了!