From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 7250 invoked by alias); 27 Dec 2012 20:59:39 -0000 Received: (qmail 7241 invoked by uid 22791); 27 Dec 2012 20:59:38 -0000 X-SWARE-Spam-Status: No, hits=-6.2 required=5.0 tests=AWL,BAYES_00,KHOP_RCVD_UNTRUST,RCVD_IN_DNSWL_HI,SPF_HELO_PASS,T_RP_MATCHES_RCVD X-Spam-Check-By: sourceware.org Received: from mx1.redhat.com (HELO mx1.redhat.com) (209.132.183.28) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Thu, 27 Dec 2012 20:59:32 +0000 Received: from int-mx01.intmail.prod.int.phx2.redhat.com (int-mx01.intmail.prod.int.phx2.redhat.com [10.5.11.11]) by mx1.redhat.com (8.14.4/8.14.4) with ESMTP id qBRKxTpN012287 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK); Thu, 27 Dec 2012 15:59:29 -0500 Received: from host2.jankratochvil.net (ovpn-116-23.ams2.redhat.com [10.36.116.23]) by int-mx01.intmail.prod.int.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id qBRKxPhr018373 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES128-SHA bits=128 verify=NO); Thu, 27 Dec 2012 15:59:28 -0500 Date: Thu, 27 Dec 2012 20:59:00 -0000 From: Jan Kratochvil To: Aleksandar Ristovski Cc: "gdb-patches@sourceware.org" Subject: Re: [patch] validate binary before use Message-ID: <20121227205924.GA5109@host2.jankratochvil.net> References: <50D4C49A.6040502@qnx.com> <50D8B37A.20001@qnx.com> <20121225073709.GA11349@host2.jankratochvil.net> <50DCAA5C.3000301@qnx.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <50DCAA5C.3000301@qnx.com> User-Agent: Mutt/1.5.21 (2010-09-15) X-IsSubscribed: yes 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/msg00823.txt.bz2 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. Section Headers: [Nr] Name Type Address Off Size ES Flg Lk Inf Al [ 3] .note.gnu.build-id NOTE 00000000004002ac 0002ac 000024 00 A 0 0 4 Program Headers: Type Offset VirtAddr PhysAddr FileSiz MemSiz Flg Align LOAD 0x000000 0x0000000000400000 0x0000000000400000 0x0d9db0 0x0d9db0 R E 0x200000 Thanks, Jan