ssh(1) multiplexing rewrite
Salvador Fandino
sfandino at yahoo.com
Fri Jan 15 03:40:44 EST 2010
Damien Miller wrote:
> Hi,
>
> At the n2k10 OpenBSD network hackathon, I finally got some time to clean
> up and rewrite the ssh(1) client multiplexing code. The attached diffs
> (one for portable OpenSSH, one for OpenBSD) are the result, and they
> need some testing.
I have repeatedly run the test suite for my Perl module Net::OpenSSH
that (ab)uses the multiplexing feature without errors.
And, while you are at it, I have some feature requests:
1) add support for sending signals to the remote processes via mux
control commands. The bug tracker contains a patch by Darren Tucker
implementing the signal part of the SSH protocol and later I submitted
another patch (now obsoleted by your changes) to request sending the
signals via mux control commands
(https://bugzilla.mindrot.org/show_bug.cgi?id=1424).
2) add support for the new netcat-like feature over mux.
3) allow to run the mux server over SSH stdin instead of over a named
Unix socket. That would be useful to embed ssh inside another program.
For instance, Net::OpenSSH internally starts a new ssh in master mode
and then sends commands to the remote machine through the mux socket
running slave ssh processes, one per command.
Handling the named Unix socket is a nuisance because it means accessing
the file system, looking for a proper location to place the socket,
checking that permissions are right, avoiding collisions with other
instances of the module concurrently running and cleaning up.
To add this feature to OpenSSH, besides allowing attaching the mux
server to stdio, the protocol should also be modified in order to allow
interleaving requests and responses related to different channels over
the same mux stream, for instance including some session ID.
It would also require making the mux protocol public so that it could be
implemented by third party clients.
From my POV, feature 1 is a must, 2 would be nice to have and 3...
well, it is more on the mental masturbation side.
I could put some effort on writing patches for 1 or 2 but only if there
exists some possibility of getting then accepted.
Cheers,
- Salva
More information about the openssh-unix-dev
mailing list