diff options
author | Theo de Raadt <deraadt@cvs.openbsd.org> | 2016-06-21 15:25:39 +0000 |
---|---|---|
committer | Theo de Raadt <deraadt@cvs.openbsd.org> | 2016-06-21 15:25:39 +0000 |
commit | 4f908dbab81e31a5ed85d33cfc5f13efa43a042f (patch) | |
tree | c2120b73bc474bea02b95aa6027a5a7e6f3f9163 /libexec/ld.so/arm | |
parent | 7e69dbfca45ff61a2865b4132a3ba615e1291693 (diff) |
When handling DT_TEXTREL only set the mapping to READ+WRITE, ignore
possible EXEC permission for the section, because the proper permission
is set late, and there are no thread concerns here. Avoids W^X issues
in oddball cases.
ok guenther kettenis
Diffstat (limited to 'libexec/ld.so/arm')
-rw-r--r-- | libexec/ld.so/arm/rtld_machine.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/libexec/ld.so/arm/rtld_machine.c b/libexec/ld.so/arm/rtld_machine.c index e3f8722e848..4bc65bb8791 100644 --- a/libexec/ld.so/arm/rtld_machine.c +++ b/libexec/ld.so/arm/rtld_machine.c @@ -1,4 +1,4 @@ -/* $OpenBSD: rtld_machine.c,v 1.22 2015/11/02 07:02:53 guenther Exp $ */ +/* $OpenBSD: rtld_machine.c,v 1.23 2016/06/21 15:25:37 deraadt Exp $ */ /* * Copyright (c) 2004 Dale Rahn @@ -194,7 +194,7 @@ _dl_md_reloc(elf_object_t *object, int rel, int relsz) llist = llist->next) { if (!(llist->prot & PROT_WRITE)) _dl_mprotect(llist->start, llist->size, - llist->prot|PROT_WRITE); + PROT_READ | PROT_WRITE); } } |