lists.openwall.net | lists / announce owl-users owl-dev john-users john-dev passwdqc-users yescrypt popa3d-users / oss-security kernel-hardening musl sabotage tlsify passwords / crypt-dev xvendor / Bugtraq Full-Disclosure linux-kernel linux-netdev linux-ext4 linux-hardening PHC | |
Open Source and information security mailing list archives
| ||
|
Date: Wed, 23 Feb 2022 21:40:11 -0800 From: Kees Cook <keescook@...omium.org> To: Eric Biederman <ebiederm@...ssion.com> Cc: Kees Cook <keescook@...omium.org>, Peter Collingbourne <pcc@...gle.com>, Catalin Marinas <catalin.marinas@....com>, Dave Martin <Dave.Martin@....com>, linux-kernel@...r.kernel.org, linux-mm@...ck.org, linux-hardening@...r.kernel.org Subject: [PATCH] ELF: Properly redefine PT_GNU_* in terms of PT_LOOS The PT_GNU_* program header types are actually offsets from PT_LOOS, so redefine them as such, reorder them, and add the missing PT_GNU_RELRO. Cc: Eric Biederman <ebiederm@...ssion.com> Cc: Peter Collingbourne <pcc@...gle.com> Cc: Catalin Marinas <catalin.marinas@....com> Cc: Dave Martin <Dave.Martin@....com> Signed-off-by: Kees Cook <keescook@...omium.org> --- include/uapi/linux/elf.h | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/include/uapi/linux/elf.h b/include/uapi/linux/elf.h index 61bf4774b8f2..6438d55529bf 100644 --- a/include/uapi/linux/elf.h +++ b/include/uapi/linux/elf.h @@ -35,10 +35,11 @@ typedef __s64 Elf64_Sxword; #define PT_HIOS 0x6fffffff /* OS-specific */ #define PT_LOPROC 0x70000000 #define PT_HIPROC 0x7fffffff -#define PT_GNU_EH_FRAME 0x6474e550 -#define PT_GNU_PROPERTY 0x6474e553 - +#define PT_GNU_EH_FRAME (PT_LOOS + 0x474e550) #define PT_GNU_STACK (PT_LOOS + 0x474e551) +#define PT_GNU_RELRO (PT_LOOS + 0x474e552) +#define PT_GNU_PROPERTY (PT_LOOS + 0x474e553) + /* * Extended Numbering -- 2.30.2
Powered by blists - more mailing lists