From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 29960 invoked by alias); 28 May 2014 13:33:02 -0000 Mailing-List: contact libffi-discuss-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: libffi-discuss-owner@sourceware.org Received: (qmail 29938 invoked by uid 89); 28 May 2014 13:33:01 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-2.6 required=5.0 tests=AWL,BAYES_00,RP_MATCHES_RCVD,SPF_PASS autolearn=ham version=3.3.2 X-HELO: smtp.gentoo.org Received: from smtp.gentoo.org (HELO smtp.gentoo.org) (140.211.166.183) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with (AES256-GCM-SHA384 encrypted) ESMTPS; Wed, 28 May 2014 13:32:59 +0000 Received: from [10.184.101.62] (unknown [85.76.147.7]) (using TLSv1 with cipher ECDHE-RSA-AES128-SHA (128/128 bits)) (No client certificate requested) (Authenticated sender: ssuominen) by smtp.gentoo.org (Postfix) with ESMTPSA id 94E1D33F82B for ; Wed, 28 May 2014 13:32:57 +0000 (UTC) Message-ID: <5385E51A.8030000@gentoo.org> Date: Wed, 28 May 2014 13:33:00 -0000 From: Samuli Suominen User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:24.0) Gecko/20100101 Thunderbird/24.4.0 MIME-Version: 1.0 To: libffi-discuss@sourceware.org Subject: [patch] libffi.so.6 in libffi-3.1 is built with execstacks because of missing GNU stack marking in win32.S Content-Type: multipart/mixed; boundary="------------030601000205000805090205" X-IsSubscribed: yes X-SW-Source: 2014/txt/msg00058.txt.bz2 This is a multi-part message in MIME format. --------------030601000205000805090205 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Content-length: 591 Downstream report you should read, http://bugs.gentoo.org/show_bug.cgi?id=511634 Basically Makefile's are always including src/x86/win32.S even on a non-windows system, and win32.S is missing the GNU stack marking other files already have: Makefile.am has: if X86 nodist_libffi_la_SOURCES += src/x86/ffi.c src/x86/sysv.S src/x86/win32.S endif and it doesn't have the #if defined __ELF__ && defined __linux__ .section .note.GNU-stack,"",@progbits #endif other files like sysv.S, unix64.S, freebsd.S, already have The attached patch fixes the executable stack in libffi.so.6 --------------030601000205000805090205 Content-Type: text/x-patch; name="libffi-3.1-execstack.patch" Content-Transfer-Encoding: 7bit Content-Disposition: attachment; filename="libffi-3.1-execstack.patch" Content-length: 218 http://bugs.gentoo.org/511634 --- src/x86/win32.S +++ src/x86/win32.S @@ -1304,3 +1304,6 @@ #endif /* !_MSC_VER */ +#if defined __ELF__ && defined __linux__ + .section .note.GNU-stack,"",@progbits +#endif --------------030601000205000805090205--