[PATCH] ControlCommand: execute a command if no control socket is available

Bert Wesarg bert.wesarg at googlemail.com
Thu Jul 9 17:53:16 EST 2009


On Thu, Jul 9, 2009 at 09:29, Helmut Grohne<helmut at subdivi.de> wrote:
> On Thu, Jul 09, 2009 at 09:12:01AM +0200, Bert Wesarg wrote:
>> The simpliest configuration would be:
>>
>> ControlMaster  command
>> ControlCommand "ssh -nNfM -p %p %u@%h"
>
> Interesting. It looks like one control master nastyness goes away. :-)
I abuse this too, to mount also sshfs shares in the background ;-)

Oh, and I blogged about this:

  http://www.nrtm.de/index.php/2009/05/26/connection-sharing-with-openssh/

>
> Your patch could also be abused for my task by badly mixing
> ControlMaster configuration. However a separated approach should be much
> cleaner.
>
>> The patch removes also the redundant check in ssh_local_cmd() for the
>> permit_local_command option, because all callsites check this in-front of the
>> call.
>
> Good. I did not check that.
>
>> ---
>>  mux.c        |   24 +++++++++++++++++++-----
>>  readconf.c   |   15 +++++++++++++--
>>  readconf.h   |    3 +++
>>  ssh.c        |   40 +++++++++++++++++++++++++++++++++++-----
>>  sshconnect.c |    3 +--
>>  5 files changed, 71 insertions(+), 14 deletions(-)
>
> I'd suggest that your patch also changes ssh_config.5. It would have to
> be documented anyway before it can be applied, so you can do that
> beforehand.
Thats correct. I didn't mean to request inclusion, just for RFC (which
I should have put into the subject)

Bert
>
> Helmut
>


More information about the openssh-unix-dev mailing list