Home
Reading
Searching
Subscribe
Sponsors
Statistics
Posting
Contact
Spam
Lists
Links
About
Hosting
Filtering
Features Download
Marketing
Archives
FAQ
Blog
 
Gmane
From: X2Go dev team <git-admin-P0WSJaAXTow <at> public.gmane.org>
Subject: x2goserver.git - master (branch) updated: 3.1.1.3-215-g538f5a7
Newsgroups: gmane.linux.terminal-server.x2go.scm
Date: Thursday 24th October 2013 07:00:53 UTC (over 2 years ago)
The branch, master has been updated
       via  538f5a7d20af6a74e8a6720214030d216a39329b (commit)
      from  6b7b20325f154f16a9c22c22187690521f90b213 (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 -----------------------------------------------------------------
commit 538f5a7d20af6a74e8a6720214030d216a39329b
Author: Helmer Teles 
Date:   Thu Oct 24 08:59:26 2013 +0200

    Make umask that is used when mounting client-side folders via SSHFS
configurable in x2goserver.conf. (Fixes: #331).

-----------------------------------------------------------------------

Summary of changes:
 debian/changelog               |    5 +++++
 x2goserver/bin/x2gomountdirs   |   17 +++++++++++++++--
 x2goserver/etc/x2goserver.conf |    4 ++++
 3 files changed, 24 insertions(+), 2 deletions(-)

The diff of changes is:
diff --git a/debian/changelog b/debian/changelog
index 4af91da..ecc5d6e 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -78,6 +78,11 @@ x2goserver (4.0.1.7-0~x2go1) UNRELEASED; urgency=low
     - Move xfonts-base from Recommends: field to Depends: field
(bin:package
       x2goserver).
 
+  [ Helmer Teles ]
+  * New upstream version (4.0.1.7):
+    - Make umask that is used when mounting client-side folders via SSHFS
+      configurable in x2goserver.conf. (Fixes: #331).
+
   [ Jürgen Hötzel ]
   * New upstream version (4.0.1.7):
     - Use bash-builtin 'type' instead of to be avoided 'which'. (Fixes:
#305).
diff --git a/x2goserver/bin/x2gomountdirs b/x2goserver/bin/x2gomountdirs
index 3152fb2..0cb31c3 100755
--- a/x2goserver/bin/x2gomountdirs
+++ b/x2goserver/bin/x2gomountdirs
@@ -246,15 +246,28 @@ for (my $i=0;$i<@dirs;$i++)
 
 	if (db_insertmount( $session, $mntpath, $host))
 	{
+
+		my $Config = new Config::Simple(syntax=>'ini');
+		$Config->read('/etc/x2go/x2goserver.conf' );
+		my $umask=$Config->param("security.umask");
+		my $umaskstr="";
+
+		if ($umask ne "")
+		{
+			$umaskstr="umask=$umask";
+		} else {
+			$umaskstr="default_permissions";
+		}
 		my $code_conv=$ENV{'X2GO_ICONV'};
+
 		if ($code_conv ne "")
 		{
 			$code_conv="-o $code_conv";
 		}
-		$msg = "sshfs $code_conv -o idmap=user,uid=`id -u`,gid=`id
-g`,ServerAliveInterval=300,Cipher=blowfish,IdentityFile=$key,UserKnownHostsFile=$key.ident
\"$user\"\@$host:\"@dirs[$i]\" \"$mntpath\" -p $port";
+		$msg = "sshfs $code_conv -o idmap=user,uid=`id -u`,gid=`id
-g`,$umaskstr,ServerAliveInterval=300,Cipher=blowfish,IdentityFile=$key,UserKnownHostsFile=$key.ident
\"$user\"\@$host:\"@dirs[$i]\" \"$mntpath\" -p $port";
 		syslog('debug', "executing: $msg");
 		print "inserted, $msg\n";
-		if (system("sshfs  $code_conv -o idmap=user,uid=`id -u`,gid=`id
-g`,ServerAliveInterval=300,Cipher=blowfish,IdentityFile=$key,UserKnownHostsFile=$key.ident
\"$user\"\@$host:\"@dirs[$i]\" \"$mntpath\" -p $port 2>>~/mounts.log")==0)
+		if (system("sshfs  $code_conv -o idmap=user,uid=`id -u`,gid=`id
-g`,$umaskstr,ServerAliveInterval=300,Cipher=blowfish,IdentityFile=$key,UserKnownHostsFile=$key.ident
\"$user\"\@$host:\"@dirs[$i]\" \"$mntpath\" -p $port 2>>~/mounts.log")==0)
 		{
 			print "mount @dirs[$i] ok\n";
 			syslog('notice', "successfully mounted $user\@$host:[email protected][$i] to
$mntpath");
diff --git a/x2goserver/etc/x2goserver.conf
b/x2goserver/etc/x2goserver.conf
index 5fa6baf..c9fe270 100644
--- a/x2goserver/etc/x2goserver.conf
+++ b/x2goserver/etc/x2goserver.conf
@@ -4,6 +4,10 @@
 [limit groups]
 #bar-group=1
 
+[security]
+# SSHFS umask for client-side folder sharing. Leave uncommented to keep
the server's default umask
+#umask="0117"
+
 [log]
 # possible levels are: emerg, alert, crit, err, warning, notice, info,
debug
 loglevel=notice


hooks/post-receive
-- 
x2goserver.git (X2Go Server)

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 "x2goserver.git" (X2Go Server).

_______________________________________________
X2Go-commits mailing list
[email protected]
https://lists.berlios.de/mailman/listinfo/x2go-commits
 
CD: 39ms