From: Michael Tremer Date: Fri, 28 May 2021 16:37:20 +0000 (+0000) Subject: check-hardening: Fix inverted check logic X-Git-Tag: 0.9.28~1285^2~52 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=2b4d55518a79f72343802ba50d66571fffca70d0;p=pakfire.git check-hardening: Fix inverted check logic Signed-off-by: Michael Tremer --- diff --git a/src/scripts/check-hardening b/src/scripts/check-hardening index da1ba3f47..5149010ee 100644 --- a/src/scripts/check-hardening +++ b/src/scripts/check-hardening @@ -64,12 +64,12 @@ main() { fi # Is this file built with -fPIC? - if ! readelf -h "${file}" 2>/dev/null | grep -qE "Type:[[:space:]]*EXEC"; then + if readelf -h "${file}" 2>/dev/null | grep -qE "Type:[[:space:]]*EXEC"; then no_pie+=( "${file}" ) fi # Does this file have an executable stack? - if ! readelf -l "${file}" 2>/dev/null | grep -A1 "GNU_STACK" | grep -q "RWE"; then + if readelf -l "${file}" 2>/dev/null | grep -A1 "GNU_STACK" | grep -q "RWE"; then exec_stack+=( "${file}" ) fi