[X2Go-Commits] python-x2go.git - release/0.4.0.x (branch) updated: 0.1.0.3-46-g009a7d9

X2Go dev team git-admin at x2go.org
Tue Jan 7 16:17:15 CET 2014


The branch, release/0.4.0.x has been updated
       via  009a7d9f70834ad66f535b71ac4d1670a6009b0e (commit)
      from  c9357984185ea987a4378fba4c3b5236e440cb4c (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.

- Log -----------------------------------------------------------------
-----------------------------------------------------------------------

Summary of changes:
 debian/changelog |    2 ++
 x2go/session.py  |   13 ++++++++-----
 2 files changed, 10 insertions(+), 5 deletions(-)

The diff of changes is:
diff --git a/debian/changelog b/debian/changelog
index bad9996..5e8cef8 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -27,6 +27,8 @@ python-x2go (0.1.1.0-0~x2go1) UNRELEASED; urgency=low
     - Do not start X2go service tunnels (audio, sshfs) if session startup failed.
     - Fix NX proxy startup post-check.
     - Force 16bit colour depth for RDP-proxy sessions.
+    - Faulty sessions (without a NX proxy fw tunnel) will get terminated whenever
+      the X2go server (SSHd) denies the tunnel setup.
 
  -- Mike Gabriel <mike.gabriel at das-netzwerkteam.de>  Thu, 23 Jun 2011 08:34:14 +0200
 
diff --git a/x2go/session.py b/x2go/session.py
index 02d78f4..89499c3 100644
--- a/x2go/session.py
+++ b/x2go/session.py
@@ -304,6 +304,9 @@ class X2goSession(object):
         else:
             self.logger('HOOK_forwarding_tunnel_setup_failed: Forwarding tunnel request to [%s]:%s for session %s (%s) was denied by remote X2go/SSH server. Session startup failed.' % (chain_host, chain_port, self.session_name, self.profile_name), loglevel=log.loglevel_WARN)
 
+        # get rid of the faulty session...
+        self.terminate()
+
     def HOOK_check_host_dialog(self, host, port, fingerprint='no fingerprint', fingerprint_type='RSA'):
         """\
         HOOK method: called if a host check is requested. This hook has to either return C{True} (default) or C{False}.
@@ -967,22 +970,22 @@ class X2goSession(object):
             if self.has_terminal_session() and not self.faulty:
 
                 if SUPPORTED_SOUND and self.terminal_session.params.snd_system is not 'none':
-                    self.terminal_session.start_sound()
+                    self.terminal_session and not self.faulty and self.terminal_session.start_sound()
 
                 if (SUPPORTED_PRINTING and self.printing) or \
                    (SUPPORTED_MIMEBOX and self.allow_mimebox) or \
                    (SUPPORTED_FOLDERSHARING and self.allow_share_local_folders):
-                    self.terminal_session.start_sshfs()
+                    self.terminal_session and not self.faulty and self.terminal_session.start_sshfs()
 
                 try:
                     if SUPPORTED_PRINTING and self.printing:
-                        self.terminal_session.start_printing()
-                        self.session_environment.update({'X2GO_SPOOLDIR': self.terminal_session.get_printing_spooldir(), })
+                        self.terminal_session and not self.faulty and self.terminal_session.start_printing()
+                        self.terminal_session and not self.faulty and self.session_environment.update({'X2GO_SPOOLDIR': self.terminal_session.get_printing_spooldir(), })
                 except X2goUserException:
                     pass
 
                 if SUPPORTED_MIMEBOX and self.allow_mimebox:
-                    self.terminal_session.start_mimebox(mimebox_extensions=self.mimebox_extensions, mimebox_action=self.mimebox_action)
+                    self.terminal_session and not self.faulty and self.terminal_session.start_mimebox(mimebox_extensions=self.mimebox_extensions, mimebox_action=self.mimebox_action)
                     self.session_environment.update({'X2GO_MIMEBOX': self.terminal_session.get_mimebox_spooldir(), })
 
                 if SUPPORTED_FOLDERSHARING and self.share_local_folders:


hooks/post-receive
-- 
python-x2go.git (Python X2Go Client API)

This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "python-x2go.git" (Python X2Go Client API).




More information about the x2go-commits mailing list