Subject: x2go server refuses client with 'Error: Wrong version or invalid session authentication cookie.'

From: harry mangalam <[email-masked]>
Date: Sun, 13 Oct 2013 21:34:07 -0700

Package: x2goserver
Version: 4.0.1 
x86_64, CentOS 6.4, kernel 2.6.32-358.18.1.el6.centos.plus.x86_64

(also x2go version 4.0.1.6 (self-compiled) on the same platform)

Problem:
After a server OS lockup and reboot, the previously working x2goserver would 
not allow client connections from Mac, Linux, Windows.  After re-installing 
x2gserver (x2goserver-4.0.1.6-1.1.x86_64) and x2goagent 
(x2goagent-3.5.0.20-4.1.x86_64), it refused to connect with the client-side 
message:

===
Session: Starting session at 'Fri Oct 11 18:11:36 2013'.
Info: Connecting to remote host 'localhost:31030'.
Info: Connection to remote proxy 'localhost:31030' established.
Error: The remote NX proxy closed the connection.
Error: Failure negotiating the session in stage '7'.
Error: Wrong version or invalid session authentication cookie.
Session: Terminating session at 'Fri Oct 11 18:11:37 2013'.
Session: Session terminated at 'Fri Oct 11 18:11:37 2013'.
===
(dont know if this is complete since the popup only lasts 2s.)
This error has been cited multiple times in various fora and lists, but no one 
seems to have been able to solve it.  

I can passwordlessly ssh to both servers just fine from other Linux clients. 

If I don't use the ssh keys, I can enter my password and the result is the 
same. 

The server seems to be initializing the session since if I try to log in 
multiple times, there are new sessions listed, but I'm not allowed to connect 
to them. I can only terminate or suspend them.  

Terminating them does appear to work since they are not listed on following 
sessions if I do.  

The problem does seem to be related to authentication or authorization; we use 
ldap-based auth on the server and it's working fine otherwise, except for 
x2go.

Thanks for your work!

harry

---
Harry Mangalam - Research Computing, OIT, Rm 225 MSTB, UC Irvine
[m/c 2225] / 92697 Google Voice Multiplexer: (949) 478-4487
415 South Circle View Dr, Irvine, CA, 92697 [shipping]
MSTB Lat/Long: (33.642025,-117.844414) (paste into Google Maps)
---