[X2Go-Commits] python-x2go.git - brokerclient (branch) updated: 36dda749f6fccc7810173d09caad2a221d84b143

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


The branch, brokerclient has been updated
       via  36dda749f6fccc7810173d09caad2a221d84b143 (commit)
      from  610fb4266a3cc83d196e74fa49330f94917c3791 (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:
 x2go/backends/control/_stdout.py |    3 ++-
 x2go/sshproxy.py                 |    2 ++
 x2go/utils.py                    |    6 ++++++
 3 files changed, 10 insertions(+), 1 deletion(-)

The diff of changes is:
diff --git a/x2go/backends/control/_stdout.py b/x2go/backends/control/_stdout.py
index 06139f9..9121587 100644
--- a/x2go/backends/control/_stdout.py
+++ b/x2go/backends/control/_stdout.py
@@ -139,7 +139,8 @@ class X2goControlSessionSTDOUT(paramiko.SSHClient):
             self.set_missing_host_key_policy(paramiko.AutoAddPolicy())
 
         if self.known_hosts is not None:
-            self.load_host_keys(known_hosts)
+            utils.touch_file(self.known_hosts)
+            self.load_host_keys(self.known_hosts)
 
     def __del__(self):
 
diff --git a/x2go/sshproxy.py b/x2go/sshproxy.py
index c879bff..d5eafe8 100644
--- a/x2go/sshproxy.py
+++ b/x2go/sshproxy.py
@@ -33,6 +33,7 @@ import threading
 # Python X2go modules
 import x2go.forward as forward
 import x2go.log as log
+import x2go.utils as utils
 from x2go.x2go_exceptions import *
 
 from x2go.defaults import CURRENT_LOCAL_USER as _CURRENT_LOCAL_USER
@@ -103,6 +104,7 @@ class X2goSSHProxy(paramiko.SSHClient, threading.Thread):
         paramiko.SSHClient.__init__(self)
 
         if known_hosts:
+            utils.touch_file(known_hosts)
             self.load_host_keys(known_hosts)
 
         if add_to_known_hosts:
diff --git a/x2go/utils.py b/x2go/utils.py
index fe8b289..5d5c2d2 100644
--- a/x2go/utils.py
+++ b/x2go/utils.py
@@ -230,3 +230,9 @@ def session_names_by_timestamp(session_infos):
     return [ session_name.split('|')[1] for session_name in sortable_session_names ]
 
 
+def touch_file(filename):
+
+    if not os.path.isdir(os.path.dirname(filename)):
+        os.makedirs(os.path.dirname(filename), mode=00700)
+    f = open(filename, 'w')
+    f.close()


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