[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Bug#731950: marked as done (ssh -g has no effect if master socket already open)



Your message dated Fri, 19 Dec 2014 18:46:50 +0000
with message-id <5494729A.9030705@gmail.com>
and subject line 
has caused the Debian Bug report #731950,
regarding ssh -g has no effect if master socket already open
to be marked as done.

This means that you claim that the problem has been dealt with.
If this is not the case it is now your responsibility to reopen the
Bug report if necessary, and/or fix the problem forthwith.

(NB: If you are a system administrator and have no idea what this
message is talking about, this may indicate a serious mail system
misconfiguration somewhere. Please contact owner@bugs.debian.org
immediately.)


-- 
731950: http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=731950
Debian Bug Tracking System
Contact owner@bugs.debian.org with problems
--- Begin Message ---
Package: openssh-client
Version: 1:5.9p1-5
Control: found -1 1:6.4p1-1

From the man page:
 -g      Allows remote hosts to connect to local forwarded ports.

When working with a control socket, this works fine if -g is included with the initial connect attempt, for example:

$ cat ~/.ssh/config
Host *
ControlMaster		auto
ControlPath		~/.ssh/%r@%h:%p

$ ssh -gTfNL 12345:localhost:12345 host
$ netstat -tln

tcp 0 0 0.0.0.0:12345 0.0.0.0:* LISTEN -

$ lsof -n

ssh 182446 user 3u IPv4 76397177 0t0 TCP 192.168.0.9:51181->192.168.0.15:ssh (ESTABLISHED) ssh 182446 user 4u IPv4 76397181 0t0 TCP *:3128 (LISTEN) ssh 182446 user 5u IPv6 76397182 0t0 TCP *:3128 (LISTEN)

and similarly:

$ ssh -g host
user@host:~$ exit
$ ssh -gTfNL 12345:localhost:12345 host
$ netstat -tln

tcp 0 0 0.0.0.0:12345 0.0.0.0:* LISTEN -

However, if it isn't then -g is ignored on subsequent attempts to forward ports:

$ ssh host
user@host:~$ exit
$ ssh -g -L 12345:localhost:12345 host
$ netstat -tln

tcp 0 0 127.0.0.1:12345 0.0.0.0:* LISTEN -

$ lsof -n

ssh 182399 user 3u IPv4 76390396 0t0 TCP 192.168.0.9:51178->192.168.0.15:ssh (ESTABLISHED) ssh 182399 user 4u unix 0x0000000000000000 0t0 76390976 /home/user/.ssh/user@host ssh 182399 user 6u IPv6 76392394 0t0 TCP [::1]:3128 (LISTEN) ssh 182399 user 7u IPv4 76392395 0t0 TCP 127.0.0.1:3128 (LISTEN)

This doesn't really make sense: ssh should still be capable of binding to the correct address as requested.

Originally reported:
https://bugs.launchpad.net/ubuntu/+source/openssh/+bug/1259939

--- End Message ---
--- Begin Message --- This should be fixed in 6.6 or 6.7 but I can't find it in the changelog. It is fixed upstream.
--- End Message ---

Reply to: