From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 8485 invoked by alias); 27 Dec 2012 21:03:12 -0000 Received: (qmail 8476 invoked by uid 22791); 27 Dec 2012 21:03:11 -0000 X-SWARE-Spam-Status: No, hits=-3.2 required=5.0 tests=AWL,BAYES_00,KHOP_THREADED,RCVD_IN_HOSTKARMA_YE X-Spam-Check-By: sourceware.org Received: from na3sys009aog130.obsmtp.com (HELO na3sys009aog130.obsmtp.com) (74.125.149.143) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Thu, 27 Dec 2012 21:03:05 +0000 Received: from mx20.qnx.com ([72.1.200.103]) (using TLSv1) by na3sys009aob130.postini.com ([74.125.148.12]) with SMTP ID DSNKUNy3iD65qxxFhvnbhRP0g/yDKnc1S3Wb@postini.com; Thu, 27 Dec 2012 13:03:05 PST Received: by mx20.qnx.com (Postfix, from userid 500) id 5758021103; Thu, 27 Dec 2012 16:03:04 -0500 (EST) Received: from exhts.ott.qnx.com (exhts2 [10.222.2.120]) (using TLSv1 with cipher AES128-SHA (128/128 bits)) (No client certificate requested) by mx20.qnx.com (Postfix) with ESMTPS id 21ECC21101; Thu, 27 Dec 2012 16:03:04 -0500 (EST) Received: from [10.222.96.215] (10.222.96.215) by exhts2.ott.qnx.com (10.222.2.25) with Microsoft SMTP Server id 14.2.318.1; Thu, 27 Dec 2012 16:03:04 -0500 Message-ID: <50DCB787.6020601@qnx.com> Date: Thu, 27 Dec 2012 21:03:00 -0000 From: Aleksandar Ristovski User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:17.0) Gecko/17.0 Thunderbird/17.0 MIME-Version: 1.0 To: Jan Kratochvil CC: "gdb-patches@sourceware.org" Subject: Re: [patch] validate binary before use References: <50D4C49A.6040502@qnx.com> <50D8B37A.20001@qnx.com> <20121225073709.GA11349@host2.jankratochvil.net> <50DCAA5C.3000301@qnx.com> <20121227205924.GA5109@host2.jankratochvil.net> In-Reply-To: <20121227205924.GA5109@host2.jankratochvil.net> Content-Type: text/plain; charset="ISO-8859-1"; format=flowed Content-Transfer-Encoding: 7bit Mailing-List: contact gdb-patches-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-patches-owner@sourceware.org X-SW-Source: 2012-12/txt/msg00824.txt.bz2 On 12-12-27 03:59 PM, Jan Kratochvil wrote: > On Thu, 27 Dec 2012 21:06:52 +0100, Aleksandar Ristovski wrote: >> build-id would be great if it was required by the standard > > GDB can check if it exists and do something as a fallback if it does not exist. > Such as printing a warning and possibly also verifying the program headers, if > compatibility with binaries from old toolchain and/or toolchain without > configured ld --build-id is required in some situations (which I doubt). > > >> and mapped into loadable segments. > > It is mapped, because one of its purposes is to get dumped into a core file. > In fact there is a special care to make it always present in the first page. Ok I didn't know that (we are not using it). In any case, what I am trying to do does not disqualify build-id (I'll use it in fact, if present). Note also that I really want a solution that does *not* rely on section headers but rather only on load-time required stuff. Thanks, Aleksandar