Subject: Bug#1584: pyhoca-cli cannot launch XDMCP session

From: Eric Monson <[email-masked]>
Date: Thu, 3 Mar 2022 13:17:45 -0700

Package: pyhoca-cli
Version: 0.4.0.3

I'm attempting to launch an XDMCP session that is suspendable and
transferable from one workstation to another. My setup has two workstations
each of which can connect to a "session-server", which in turn does an
xdmcp query to a host I'll call "xserver". Note that the xserver in this
setup is an old solaris machine that runs X, but doesn't have the x2go
server packages installed.

Here's my ascii diagram of what I tried to convey above:
workstation1/workstation2 (x2goclient, pyhoca-gui and pyhoca-cli
installed)  ->   session-server (x2goserver installed)  ->  xserver (xdmcp
enabled)

I set up a session using "pyhoca-gui", which results in the following:

------------------------------
[20220303170339880609]
user = username
defsndport = 1
sshproxyautologin = 1
forwardsshagent = 0
useiconv = 0
iconvfrom = UTF-8
height = 600
uniquehostkeyaliases = 0
directrdp = 0
sshproxysameuser = 0
sshproxysamepass = 0
quality = 9
maxdim = 0
fullscreen = 0
sessiontitle =
layout = us
useexports = 0
sshproxytype = SSH
width = 800
speed = 4
xdmcpserver = xserver
sshproxyuser =
rdpoptions = -u X2GO_USER -p X2GO_PASSWORD
soundsystem = pulse
clipboard = both
autostart = 0
print = 0
type = pc105/us
setsessiontitle = 0
sndport = 4713
usesshproxy = 0
usemimebox = 0
xinerama = 0
usekbd = 1
variant =
autologin = 1
sshproxykeyfile =
sshproxyport = 22
applications = TERMINAL, WWWBROWSER, MAILCLIENT, OFFICE
host = session-server
display = 1
mimeboxextensions =
multidisp = 0
key =
directrdpsettings =
fstunnel = 1
icon = :icons/128x128/x2gosession.png
sound = 0
autoconnect = 0
rootless = 0
mimeboxaction = OPEN
name = pyhoca-xdmcp
rdpport = 3389
iconvto = UTF-8
rdpserver =
restoreexports = 0
soundtunnel = 1
sshproxyhost = proxyhost.mydomain
rdpclient = rdesktop
command = XDMCP
startsoundsystem = 0
published = 0
sshport = 22
export =
setdpi = 0
krblogin = 0
dpi = 96
pack = 16m-jpeg
------------------------------

When I use x2goclient, I'm able to launch the session, suspend the session,
and transfer the session between workstations as expected.

When I use pyhoca-cli to create the session, I get the following results:

% pyhoca-cli --server session-server -N -P pyhoca-xdmcp
pyhoca-cli[16544] NOTICE: preparing requested X2Go session
pyhoca-cli[16544] (PyHocaCLI) NOTICE: preparing requested X2Go session
pyhoca-cli[16544] (x2gosessregistry-pylib) NOTICE: registering X2Go session
pyhoca-xdmcp...
pyhoca-cli[16544] (x2goclient-pylib) NOTICE: initializing X2Go session...
pyhoca-cli[16544] (x2gocontrolsession-pylib) NOTICE: connecting to
[session-server]:22
pyhoca-cli[16544] (x2goterminalsession-pylib) WARN: XDMCP
pyhoca-cli[16544] (x2goclient-pylib) WARN: HOOK_no_such_command: the
command XDMCP is not available for X2Go server (profile: pyhoca-xdmcp,
session: )
pyhoca-cli[16544] (x2goclient-pylib) WARN: HOOK_session_startup_failed:
session startup for session profile ,,pyhoca-xdmcp failed.
pyhoca-cli[16544] (PyHocaCLI) NOTICE: give the X2Go session some time to
come up...

I'll note here that this also doesn't work with pyhoca-gui (I'm sure I'm
supposed to write this up separately, but I think it's useful to have all
this information together in one place):

% pyhoca-gui
/usr/lib/python2.7/site-packages/pyhoca/wxgui/notify.py:27: PyGIWarning:
Notify was imported without specifying a version first. Use
gi.require_version('Notify', '0.7') before import to ensure that the right
version gets loaded.
  from gi.repository import Notify as _Notify
pyhoca-gui[16667] (PyHoca-GUI) WARN: the current release of PyHoca-GUI does
not support client configuration
pyhoca-gui[16667] (x2gosessregistry-pylib) NOTICE: registering X2Go session
pyhoca-xdmcp...
pyhoca-gui[16667] (x2goclient-pylib) NOTICE: initializing X2Go session...
pyhoca-gui[16667] (x2gocontrolsession-pylib) NOTICE: connecting to
[session-server]:22
pyhoca-gui[16667] (PyHoca-GUI) NOTICE: [pyhoca-xdmcp - connect] SSH key
authentication has been successful.
pyhoca-gui[16667] (x2gosessregistry-pylib) NOTICE: using already
initially-registered yet-unused session 0e8c5ce6-9b16-11ec-9567-1866dafa946c
pyhoca-gui[16667] (x2goclient-pylib) NOTICE: initializing X2Go session...
pyhoca-gui[16667] (x2goterminalsession-pylib) WARN: XDMCP
pyhoca-gui[16667] (PyHoca-GUI) NOTICE: [pyhoca-xdmcp - session failure] The
command ,,XDMCP'' is not available on X2Go server .
pyhoca-gui[16667] (PyHoca-GUI) NOTICE: [pyhoca-xdmcp - session failure] The
session startup failed.

Finally, I will note that if the session is created by x2goclient, then
suspended, both pyhoca-gui and pyhoca-cli can successfully resume the
session created by the x2goclient.

Here are the versions I'm running:

pyhoca-cli --version

pyhoca-cli[13520] - an X2Go command line client written in Python
----------------------------------------------------------------------
developed by Mike Gabriel <[email-masked]>

VERSION: 0.4.0.3

pyhoca-gui --version
/usr/lib/python2.7/site-packages/pyhoca/wxgui/notify.py:27: PyGIWarning:
Notify was imported without specifying a version first. Use
gi.require_version('Notify', '0.7') before import to ensure that the right
version gets loaded.
  from gi.repository import Notify as _Notify

pyhoca-gui[17078] - an X2Go GUI client written in Python
----------------------------------------------------------------------
developed by Mike Gabriel <[email-masked]>
sponsored by Dick Kniep <[email-masked]> (2010-2016)

VERSION: 0.5.0.5

---

From: Mike Gabriel <[email-masked]>
Date: Mon, 15 Jan 2024 20:46:19 +0000

Control: close -1

Issue continued at  
https://gitlab.x2go.org/x2go/client/libs/python-x2go/-/issues/7
-- 

DAS-NETZWERKTEAM
c\o Technik- und Ökologiezentrum Eckernförde
Mike Gabriel, Marienthaler Str. 17, 24340 Eckernförde
mobile: +49 (1520) 1976 148
landline: +49 (4351) 850 8940

GnuPG Fingerprint: 9BFB AEE8 6C0A A5FF BF22  0782 9AF4 6B30 2577 1B31
mail: [email-masked], http://das-netzwerkteam.de

---

From: [email-masked] (X2Go Bug Tracking System)
Date: Mon, 15 Jan 2024 20:50:03 +0000

This is an automatic notification regarding your Bug report
which was filed against the pyhoca-cli package:

#1584: pyhoca-cli cannot launch XDMCP session

It has been closed by Mike Gabriel <[email-masked]>.

Their explanation is attached below along with your original report.
If this explanation is unsatisfactory and you have not received a
better one in a separate message then please contact Mike Gabriel <[email-masked]> by
replying to this email.

-- 
1584: https://bugs.x2go.org/cgi-bin/bugreport.cgi?bug=1584
X2Go Bug Tracking System
Contact [email-masked] with problems

Subject: Closing...
From: Mike Gabriel <[email-masked]>
To: [email-masked]
Date: Mon, 15 Jan 2024 20:46:19 +0000

Control: close -1

Issue continued at  

DAS-NETZWERKTEAM

Subject: pyhoca-cli cannot launch XDMCP session
From: Eric Monson <[email-masked]>
To: [email-masked]
Date: Thu, 3 Mar 2022 13:17:45 -0700

Package: pyhoca-cli
Version: 0.4.0.3

% pyhoca-gui

pyhoca-cli --version

VERSION: 0.4.0.3

pyhoca-gui --version

VERSION: 0.5.0.5