[X2Go-Dev] Bug#922: Fwd: X2Go Server contains some IPv4/non-IPv6 logic for creating ports.

Mike Gabriel mike.gabriel at das-netzwerkteam.de
Wed Dec 30 10:50:56 CET 2015


----- Weitergeleitete Nachricht von Mike Gabriel  
<mike.gabriel at das-netzwerkteam.de> -----
   Datum: Wed, 30 Dec 2015 09:21:20 +0000
     Von: Mike Gabriel <mike.gabriel at das-netzwerkteam.de>
Betreff: [X2Go-Dev] X2Go Server contains some IPv4/non-IPv6 logic for  
creating ports.
      An: x2go-dev at lists.x2go.org

Hi guys,

On  So 23 Aug 2015 23:10:59 CEST, git-admin wrote:

> This is an automated email from the git hooks/post-receive script.
>
> x2go pushed a commit to branch master
> in repository x2goserver.
>
> commit bfe3ba761c1d3e9143285ca17edc87ac763ce35d
> Author: Mihai Moldovan <ionic at ionic.de>
> Date:   Sun Aug 23 23:08:45 2015 +0200
>
>    x2goserver/bin/x2gostartagent: changes to Robert Nowotny's  
> SSH_PORT patch. Fixes: #922.
>
>    Use default outgoing interface to determine IP address.
>
>    Use the whole range of ${RANDOM}'s pool.
>
>    Seed it for good measure.
>
>    Change the default method to randomization instead of IP-based
>    initialization.
>
>    If IP-based initialization was requested but the default outgoing IP
>    address unavailable, fall back to randomization.
>

Haven't looked at X2Go Server code for a while... Today I found the below...

> +# Get server IP address.
> +get_server_ip_address() {
> +	# The provided IP address should be outside of any local network.
> +	# We are only interested in how the kernel would try to reach the
> +	# non-local IP address specified here. It is not actually contacted
> +	# in any way.
> +	typeset ip_output="$(ip route get 8.8.8.8)"
> +
> +	# Remove newlines.
> +	ip_output="${ip_output//$'\n'}"
> +
> +	# Fetch source address.
> +	typeset src_address="$(grep -oe  
> 'src[[:space:]]\{1,\}\(\([[:digit:]]\{1,3\}\.\)\{3\}[[:digit:]]\{1,3\}\)'  
> <<< "${ip_output}" | sed -e 's/src[[:space:]]\{1,\}//')"
> +
> +	if [ -n "${src_address}" ]; then
> +		printf "${src_address}"
> +		return "0"
> +	fi
> +
> +	return "1"
> +}

Has anyone of you ever heard of IPv6? And has anyone ever seen setups  
where the IPv6 traffic is routed via a different interface compared to  
IPv4 traffic?

Furthermore, within the last years, I never had any problems with  
server-side ports being the same on different servers. I mostly  
connect through PyHoca. So if there is a problem in X2Go Client  
regarding server-side SSH tunnel ports, why--the hack--do you fix that  
in X2Go Server?

If the port allocation is a problem at all, it certainly is a problem  
that requires fixing in X2Go Client, not X2Go Server.

Please consider reverting this flawed patch!!!

Scratching my head and wondering...

Mike

----- Ende der weitergeleiteten Nachricht -----

-- 

DAS-NETZWERKTEAM
mike gabriel, herweg 7, 24357 fleckeby
fon: +49 (1520) 1976 148

GnuPG Key ID 0x25771B31
mail: mike.gabriel at das-netzwerkteam.de, http://das-netzwerkteam.de

freeBusy:
https://mail.das-netzwerkteam.de/mailxchange/kronolith/fb.php?u=m.gabriel%40das-netzwerkteam.de
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 819 bytes
Desc: Digitale PGP-Signatur
URL: <http://lists.x2go.org/pipermail/x2go-dev/attachments/20151230/bef22344/attachment.pgp>


More information about the x2go-dev mailing list