Re: connection multiplexing under cygwin

From: Darren Tucker (dtucker_at_gate.dodgy.net.au)
Date: 06/14/05


Date: 14 Jun 2005 03:28:58 GMT

On 2005-06-11, shane <invalid@hotmail.com> wrote:
> Im having some issues with the latest version of OpenSSH released for cygwin
> (under WinXP SP2).
>
> I am trying to connect to ssh.sf.net with a master connection that is
> shared. I am using:
> ssh -vv -l user -M -S ~/.ssh/sf-mux ssh.sf.net
[...]
> And both ssh sessions terminate. Anyone know whats going on?

ssh's session multiplexing uses (file) descriptor passing, and I don't
think that Cygwin is currently capable of doing that.

(I'm told that it would be extremely difficult for Cygwin to implement
descriptor passing. While Cygwin does an amazing job of papering over
the differences between Windows and *nix, on *nix descriptor passing is
implemented in the kernel and on Windows the kernel is out of Cygwin's
control.)

It's not nice of it to crash, though. I built ssh with debugging symbols
and it's crashing way inside Cygwin:

(gdb) bt
#0 0x61106323 in cygwin1!_alloca () from /usr/bin/cygwin1.dll
#1 0x610988d9 in cygwin1!aclcheck () from /usr/bin/cygwin1.dll
#2 0x610a087f in cygwin1!aclcheck () from /usr/bin/cygwin1.dll
#3 0x00408883 in client_loop (have_pty=0, escape_char_arg=-2,
    ssh2_chan_id=16) at ../../clientloop.c:1299
#4 0x00403567 in ssh_session2 () at ../../ssh.c:1211
#5 0x0040240f in _fu42__optind () at ../../ssh.c:734

I'm not entirely sure why but the very high descriptor numbers reported by
client_process_control are probably good suspects.

-- 
Darren Tucker (dtucker at zip.com.au)
GPG key 8FF4FA69 / D9A3 86E9 7EEE AF4B B2D4  37C9 C982 80C7 8FF4 FA69
    Good judgement comes with experience. Unfortunately, the experience
usually comes from bad judgement.


Relevant Pages

  • RE: Linux GPL and binary module exception clause?
    ... the COPYING file for the kernel. ... the suggestion has been to have a separate copy of the header ... > with the Cygwin toolkit for Windows. ... > using the Cygwin libraries is a derived work and must be GPL. ...
    (Linux-Kernel)
  • Re: Building the kernel with Cygwin
    ... >> After untaring the kernel, ... >> with cygwin? ... >this information by persons or entities other than the intended recipient ... send the line "unsubscribe linux-kernel" in ...
    (Linux-Kernel)
  • Re: case-sensitive file names during build
    ... I maintain patches that allow building glibc on Cygwin and MacOSX. ... The main patch deals with exactly this issue ... to help install the kernel headers, ...
    (Linux-Kernel)
  • Re: Mandatory locking
    ... Well LockFile and LockFileEx are the Win32 wrappers for ZwLockFile and ... UnlockFIle and UnlockFileEx are the ZwUnlockFile equivalents. ... Is there any support for mandatory locking in the NT kernel, ... I can control the behaviour for Cygwin processes from within the Cygwin ...
    (microsoft.public.win32.programmer.kernel)
  • Re: Building the kernel with Cygwin
    ... Building the kernel with Cygwin ... You could try giving windows absolute path. ... send the line "unsubscribe linux-kernel" in ...
    (Linux-Kernel)