I am getting a Putty attempted incorrect protocol errors when I SSH into my server from Windows
I have had Putty connecting via SSH to my Ubuntu 12.10 server for several months. Yesterday I began to get the following error every time I connect:
PuTTY X11 proxy: wrong authentication protocol attempted
I can do everything in the session except launch X Windows applications. To my knowledge nothing changed on the Windows side, and I did recently install @20 updates on the Ubuntu side during normal upgrade maintenance.
I use Xming as an X server on the Windows client. And as I said it was working just fine. I have ready dozens of Google results searching on this error and most seem to involve the error happening after an SSH connection while attempting to SU or SUDO to another account, but this is happening to my regular user connection.
I have tried deleting the .Xauthority file in my home directory, also various xauth add commands to try and get the correct "magic cookie" back into the .Xauthority file. Nothing has worked.
Any thoughts?
Solution 1:
Reformatted for ask from http://froebe.net/blog/2008/11/14/getting-xlib-putty-x11-proxy-wrong-authentication-protocol-attempted-i-have-the-answer/
As mentioned above, you can break your security by switching on ForwardX11Trusted yes
in the /etc/ssh/sshd_config
file on the server and restart sshd. The full solution is to temporarily transfer the authorization to the other account.
First, on your client get the key from your account (on windows this is for xming and might be in the xming configuration):
$ xauth list
aspc2o1/unix:10 MIT-MAGIC-COOKIE-1 bc664c66cfec3c5c3d5b0efc4ee9d3ad
Next, log into your ssh/putty account and add the xming key (this might actually be in the configuration for putty).
$ xauth add aspc2o1/unix:10 MIT-MAGIC-COOKIE-1 bc664c66cfec3c5c3d5b0efc4ee9d3ad
Now you should be able to open up apps when you forward the X display over ssh.