Ubuntu – Cannot Access SSH – “Did not receive identification string from [IP]” in Logs

puttysshUbuntu

I'm having a problem accessing SSH on my Ubuntu server from outside the network.

Accessing it using it's local IP address (192.168.1.100) works fine. Accessing from a networked PC but using the routers external IP address also works fine. The problem arises when I try to access the server from my work PC.

I had to do a bit of port forwarding as my work firewall will only allow outbound traffic on ports 80 and 443. My router will now accept connections on 443 and forward them to port 22 on my Ubuntu server and this configuration works fine in the above tests using the external IP address. However, at work I can still not connect (I'm using Putty by the way) and just get a "Server Unexpectedly Closed Network Connection" dialog.

Checking the ssh logs (auth.log) last night I can see entries which relate to my works external IP address so I know that the request was getting to the server itself but I can't find any real explanation for the error itself which reads:

Did not receive identification string from xx.xx.xx.xx << Work IP Was Here

Can anyone clarify what this means and what I need to do to resolve the problem. The SSH configuration is pretty basic and really limited to disabling root access.

Thanks in Advance

Best Answer

It means that the SSH client didn't actually speak SSH to the server. My best guess would be some sort of transparent proxy or IDS getting in the way of your traffic at work and mangling it beyond all hope of recovery. If so, install OpenVPN on 443/tcp at home, and explicitly configure the OpenVPN client to use the HTTPS proxy to connect to home (works great -- got me full 'net access from inside a stupendously locked-down government network once).