[PATCH] Cygwin: ssh-host-config script broken on casesensitive systems (was Re: openssh-5.5p1)

Corinna Vinschen vinschen at redhat.com
Wed Mar 24 03:03:47 EST 2010


Hi Damien,

On Mar 17 06:04, Damien Miller wrote:
> Hi,
> 
> We will probably do an openssh-5.5p1 release soon, mainly for the
> sshd_config:AuthorizedKeysFile bug, but containing a few other small
> patches too. If you have any portability fixes that need to go in then
> please send them through at once.

I hope I'm not too late.  I just stumbled over a problem with the
Cygwin-specific ssh-host-config script.  The script uses the Windows
pathname to the directory holding the (/etc/)services file in a
case-insensitive manner.  However, the latest Cygwin allows to use
case-sensitive paths and on systems supporting it (depends on a registry
key) the default mount mode is case-sensitive.  Unfortunately this
breaks the script!

So, it would be really nice if the below patch could still go into
OpenSSH 5.5p1.  It mounts the Windows directory containing the services
file explicitely case-insensitive.  This allows to tweak the Windows
services file reliably, which *still* does not contain the "ssh 22/tcp"
entry, even in the latest Windows 7 :(


Thanks,
Corinna


Index: contrib/cygwin/ssh-host-config
===================================================================
RCS file: /cvs/openssh/contrib/cygwin/ssh-host-config,v
retrieving revision 1.28
diff -u -p -r1.28 ssh-host-config
--- contrib/cygwin/ssh-host-config	12 Jul 2009 11:58:42 -0000	1.28
+++ contrib/cygwin/ssh-host-config	23 Mar 2010 16:02:26 -0000
@@ -90,7 +90,7 @@ update_services_file() {
   fi
   _serv_tmp="${_my_etcdir}/srv.out.$$"
 
-  mount -o text -f "${_win_etcdir}" "${_my_etcdir}"
+  mount -o text,posix=0,noacl -f "${_win_etcdir}" "${_my_etcdir}"
 
   # Depends on the above mount
   _wservices=`cygpath -w "${_services}"`


-- 
Corinna Vinschen
Cygwin Project Co-Leader
Red Hat


More information about the openssh-unix-dev mailing list