From e148ff2467907f408e2b6ef03ded4d7562634115 Mon Sep 17 00:00:00 2001 From: deraadt Date: Fri, 10 Feb 2023 03:22:12 +0000 Subject: [PATCH] Explicitly mark the text LOAD as FLAGS(5), meaning RX, with a comment. This is the default value of the linker, but I really like placing the comment "architecturally required data islands". --- libexec/ld.so/sh/ld.script | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libexec/ld.so/sh/ld.script b/libexec/ld.so/sh/ld.script index 1b84e5bc1a1..1842ee9c175 100644 --- a/libexec/ld.so/sh/ld.script +++ b/libexec/ld.so/sh/ld.script @@ -1,7 +1,7 @@ PHDRS { rodata PT_LOAD FILEHDR PHDRS FLAGS (4); - text PT_LOAD; + text PT_LOAD FLAGS (5); /* architecturally required data islands */ btext PT_LOAD FLAGS (0x08000005); data PT_LOAD; random PT_OPENBSD_RANDOMIZE; -- 2.20.1