[PATCH/RFC 0/6] New mux client request to list open tcp forwardings.

Alex Bligh alex at alex.org.uk
Thu May 3 22:35:39 EST 2012



--On 3 May 2012 13:33:46 +0200 Bert Wesarg <bert.wesarg at googlemail.com> 
wrote:

> These patches implement a new mux client request to list the currently
> opened TCP forwardings. It also removes some todos regarding keeping the
> list of forwardings in the options up-to-date.

Interesting.

I have a related application where a process on the /server/ wants to
know the list of port forwardings. In essence I have a large number of
clients all connecting using public key, and all forwarding one of
their local ports with -R, and dynamically allocating a listen port
on the server side. The server needs to establish (without being able
to trust the client) which port an ssh session with a given public
key is listening on. Currently I do this by a combination of
forcing a command on the server side, and some nasty hackery with lsof
type things. It would be useful if there were something that could
be queried on the server to definitively establish which forwarded
port was what, particularly as my method does not work with more
than one forwarded port (hence fails with autossh).

-- 
Alex Bligh


More information about the openssh-unix-dev mailing list