[X2Go-Commits] [x2goserver] 02/02: Allow usernames in session IDs of length 48 chars.

git-admin at x2go.org git-admin at x2go.org
Mon Dec 8 13:07:31 CET 2014


This is an automated email from the git hooks/post-receive script.

x2go pushed a commit to branch master
in repository x2goserver.

commit 1f7156d7d9a60553e8cce249e8eabf7ac441b661
Author: Mike Gabriel <mike.gabriel at das-netzwerkteam.de>
Date:   Mon Dec 8 12:59:38 2014 +0100

    Allow usernames in session IDs of length 48 chars.
---
 X2Go/Utils.pm    |    4 ++--
 debian/changelog |    1 +
 2 files changed, 3 insertions(+), 2 deletions(-)

diff --git a/X2Go/Utils.pm b/X2Go/Utils.pm
index 85ee445..7e9e8ac 100644
--- a/X2Go/Utils.pm
+++ b/X2Go/Utils.pm
@@ -132,8 +132,8 @@ sub sanitizer {
 		$string =~ s/[^a-zA-Z0-9\_\-\$\.\@]//g;
 		if ($string =~ /^([a-zA-Z0-9\_\-\$\.\@]*)$/) {
 			$string = $1;
-			if ($string =~ /^([a-zA-Z\_][a-zA-Z0-9\_\-\.\@]{0,31}[\$]?)\-([\d]{2,4})\-([\d]{9,12})\_[a-zA-Z0-9\_\-\.]*\_dp[\d]{1,2}$/) {
-				if ((length($1) > 0) and (length($1) < 32)){
+			if ($string =~ /^([a-zA-Z\_][a-zA-Z0-9\_\-\.\@]{0,47}[\$]?)\-([\d]{2,4})\-([\d]{9,12})\_[a-zA-Z0-9\_\-\.]*\_dp[\d]{1,2}$/) {
+				if ((length($1) > 0) and (length($1) < 48)){
 					return $string;
 				} else {return 0;}
 			} else {return 0;}
diff --git a/debian/changelog b/debian/changelog
index 0f8520d..1fad011 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -195,6 +195,7 @@ x2goserver (4.0.1.19-0x2go1) UNRELEASED; urgency=medium
       backend. (Fixes: #664).
     - Improve sanitizer, use 'x2gosid' sanitizer for session IDs everywhere.
       Drop unused 'pnixusername' sanitizer in 4.0.1.x release of X2Go Server.
+    - Allow session IDs of length 96 chars.
   * debian/control:
     + Add D (x2goserver): libfile-which-perl.
     + Add C (x2goserver: x2godesktopsharing (<< 3.1.1.2).

--
Alioth's /srv/git/_hooks_/post-receive-email on /srv/git/code.x2go.org/x2goserver.git


More information about the x2go-commits mailing list