From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from pigeon.gentoo.org ([208.92.234.80] helo=lists.gentoo.org) by finch.gentoo.org with esmtp (Exim 4.60) (envelope-from ) id 1RFuDO-0002Nv-4c for garchives@archives.gentoo.org; Mon, 17 Oct 2011 20:55:18 +0000 Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id 15C1D21C123; Mon, 17 Oct 2011 20:55:11 +0000 (UTC) Received: from smtp.gentoo.org (smtp.gentoo.org [140.211.166.183]) by pigeon.gentoo.org (Postfix) with ESMTP id DCFCD21C123 for ; Mon, 17 Oct 2011 20:55:10 +0000 (UTC) Received: from pelican.gentoo.org (unknown [66.219.59.40]) (using TLSv1 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by smtp.gentoo.org (Postfix) with ESMTPS id 625FB1B4036 for ; Mon, 17 Oct 2011 20:55:10 +0000 (UTC) Received: from localhost.localdomain (localhost [127.0.0.1]) by pelican.gentoo.org (Postfix) with ESMTP id 4E01880042 for ; Mon, 17 Oct 2011 20:55:09 +0000 (UTC) From: "Anthony G. Basile" To: gentoo-commits@lists.gentoo.org Content-type: text/plain; charset=UTF-8 Reply-To: gentoo-dev@lists.gentoo.org, "Anthony G. Basile" Message-ID: <0552fd71e796816c4ccf383b05a2592d9c0a7e1e.blueness@gentoo> Subject: [gentoo-commits] proj/elfix:master commit in: scripts/ X-VCS-Repository: proj/elfix X-VCS-Files: scripts/paxmodule.c scripts/revdep-pax X-VCS-Directories: scripts/ X-VCS-Committer: blueness X-VCS-Committer-Name: Anthony G. Basile X-VCS-Revision: 0552fd71e796816c4ccf383b05a2592d9c0a7e1e Date: Mon, 17 Oct 2011 20:55:09 +0000 (UTC) Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-Id: Gentoo Linux mail X-BeenThere: gentoo-commits@lists.gentoo.org Content-Transfer-Encoding: quoted-printable X-Archives-Salt: X-Archives-Hash: 90dcc5a7cbf3dda227ce885049745f5e commit: 0552fd71e796816c4ccf383b05a2592d9c0a7e1e Author: Anthony G. Basile gentoo org> AuthorDate: Mon Oct 17 20:55:00 2011 +0000 Commit: Anthony G. Basile gentoo org> CommitDate: Mon Oct 17 20:55:00 2011 +0000 URL: http://git.overlays.gentoo.org/gitweb/?p=3Dproj/elfix.git;a=3D= commit;h=3D0552fd71 scripts/{paxmodule.c,revdep-pax}: removed EI_PAX markings, bug #387459 --- scripts/paxmodule.c | 18 +++++++++++++++++- scripts/revdep-pax | 2 +- 2 files changed, 18 insertions(+), 2 deletions(-) diff --git a/scripts/paxmodule.c b/scripts/paxmodule.c index 32c8768..45e9f26 100644 --- a/scripts/paxmodule.c +++ b/scripts/paxmodule.c @@ -9,6 +9,7 @@ #include #include =20 +/* Gentoo bug #387459 =20 #define HF_PAX_PAGEEXEC 1 #define HF_PAX_EMUTRAMP 2 @@ -18,6 +19,7 @@ #define HF_PAX_SEGMEXEC 32 =20 #define EI_PAX 14 // Index to read the PaX flags into ELF header e_ide= nt[] array +*/ =20 #define BUF_SIZE 7 //Buffer for holding human readable flags =20 @@ -58,7 +60,9 @@ pax_getflags(PyObject *self, PyObject *args) char pax_buf[BUF_SIZE]; uint16_t pax_flags; =20 - GElf_Ehdr ehdr; + /* Gentoo bug #387459 + GElf_Ehdr ehdr;=20 + */ GElf_Phdr phdr; char found_pt_pax; size_t i, phnum; @@ -140,6 +144,12 @@ pax_getflags(PyObject *self, PyObject *args) =20 if(!found_pt_pax) { + //Set to the strictest possible + } + + /* Gentoo bug #387459 + if(!found_pt_pax) + { if(gelf_getehdr(elf, &ehdr) !=3D &ehdr) { elf_end(elf); @@ -157,6 +167,7 @@ pax_getflags(PyObject *self, PyObject *args) pax_buf[4] =3D pax_flags & HF_PAX_RANDMMAP ? 'r' : 'R'; pax_buf[5] =3D pax_flags & HF_PAX_RANDEXEC ? 'X' : 'x'; } + */ =20 elf_end(elf); close(fd); @@ -174,8 +185,10 @@ pax_setflags(PyObject *self, PyObject *args) =20 Elf *elf; =20 + /* Gentoo bug #387459 GElf_Ehdr ehdr; uint16_t ei_flags; + */ =20 GElf_Phdr phdr; size_t i, phnum; @@ -213,6 +226,8 @@ pax_setflags(PyObject *self, PyObject *args) return NULL; } =20 + /* Gentoo bug #387459 + if(gelf_getehdr(elf, &ehdr) !=3D &ehdr) { elf_end(elf); @@ -276,6 +291,7 @@ pax_setflags(PyObject *self, PyObject *args) PyErr_SetString(PaxError, "pax_setflags: gelf_update_ehdr() failed"); return NULL; } + */ =20 =20 elf_getphdrnum(elf, &phnum); diff --git a/scripts/revdep-pax b/scripts/revdep-pax index a5636bd..59b8b4e 100755 --- a/scripts/revdep-pax +++ b/scripts/revdep-pax @@ -314,7 +314,7 @@ def run_soname(name, verbose, use_soname, mark): except: print 'cannot obtain pax flags for %s' % binary =20 - if len(mismatched_binaries) =3D=3D 0 + if len(mismatched_binaries) =3D=3D 0: print print '\tNo mismatches' print