Date: Thu, 20 Aug 2009 04:01:18 GMT From: Jonathan Chen <jon@FreeBSD.org> To: freebsd-gnats-submit@FreeBSD.org Subject: ports/137985: security/openssh-portable: [PATCH] sftp crashes on directory listing Message-ID: <200908200401.n7K41IlD038849@www.freebsd.org> Resent-Message-ID: <200908200410.n7K4A3J3073441@freefall.freebsd.org>
next in thread | raw e-mail | index | archive | help
>Number: 137985 >Category: ports >Synopsis: security/openssh-portable: [PATCH] sftp crashes on directory listing >Confidential: no >Severity: serious >Priority: low >Responsible: freebsd-ports-bugs >State: open >Quarter: >Keywords: >Date-Required: >Class: sw-bug >Submitter-Id: current-users >Arrival-Date: Thu Aug 20 04:10:03 UTC 2009 >Closed-Date: >Last-Modified: >Originator: Jonathan Chen >Release: 8.0-BETA2 amd64 >Organization: >Environment: FreeBSD builder 8.0-BETA2 FreeBSD 8.0-BETA2 #0: Fri Aug 14 19:03:00 EDT 2009 jon@builder:/usr/obj/usr/src/sys/DFLT amd64 >Description: On FreeBSD, openbsd-compat's glob is supposed to be used used instead of the system glob, due to BROKEN_GLOB being set in configure. However, includes.h pulls in the system glob.h nonetheless, resulting in divergent glob_t definitions within openssh. This manifests as sftp throwing a SIGBUS when a directory listing is requested. NB: contrary to the claim in the Makefile, openssh-portable seems to compile just fine on OSVERSION==800104 (once you remove the BROKEN= line) >How-To-Repeat: cd /usr/ports/security/openssh-portable make work/openssh-5.2p1/sftp localhost [login] ls *SIGBUS* >Fix: drop the following patch into files/patch-blah --- includes.h~ 2009-08-19 23:32:26.000000000 -0400 +++ includes.h 2009-08-19 23:32:53.000000000 -0400 @@ -31,7 +31,8 @@ #endif #if defined(HAVE_GLOB_H) && defined(GLOB_HAS_ALTDIRFUNC) && \ defined(GLOB_HAS_GL_MATCHC) && \ - defined(HAVE_DECL_GLOB_NOMATCH) && HAVE_DECL_GLOB_NOMATCH != 0 + defined(HAVE_DECL_GLOB_NOMATCH) && HAVE_DECL_GLOB_NOMATCH != 0 &&\ + !defined(BROKEN_GLOB) # include <glob.h> #endif #ifdef HAVE_ENDIAN_H >Release-Note: >Audit-Trail: >Unformatted:
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200908200401.n7K41IlD038849>