From 3bc9f4bca1d3aaea67cb2c9b2143533f082e0174 Mon Sep 17 00:00:00 2001 From: Kenny MacDermid Date: Tue, 25 Jul 2023 19:35:20 -0300 Subject: [PATCH] Disable executable stacks on assembly objects Add `--noexecstack` to the assembler flags so the resulting binary will link with a non-executable stack. Fixes zerotier/ZeroTierOne#1179 --- make-linux.mk | 3 +++ 1 file changed, 3 insertions(+) diff --git a/make-linux.mk b/make-linux.mk index 94bbe0dbb..48d44a048 100644 --- a/make-linux.mk +++ b/make-linux.mk @@ -357,6 +357,9 @@ endif override CFLAGS+=-fPIC -fPIE override CXXFLAGS+=-fPIC -fPIE +# Non-executable stack +override ASFLAGS+=--noexecstack + .PHONY: all all: one