From 90b17121baf55a233a5819a0c5f8ba7fe5a387ba Mon Sep 17 00:00:00 2001 From: Brian Ginsbach Date: Sun, 29 Mar 2020 15:31:41 -0500 Subject: [PATCH] Fix AUTH-9230 for systems without /etc/login.defs This fixes a bug where it was determined that /etc/login.defs didn't exist as a prerequisite but then wasn't used to skip the test. Prevents warnings from `grep(1)` for "no such file or directory". --- include/tests_authentication | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/include/tests_authentication b/include/tests_authentication index ce821fba..81842b63 100644 --- a/include/tests_authentication +++ b/include/tests_authentication @@ -396,7 +396,7 @@ if [ -f ${ROOTDIR}etc/login.defs ]; then PREQS_MET="YES" fi - Register --test-no AUTH-9230 --root-only NO --weight L --network NO --category security --description "Check group password hashing rounds" + Register --test-no AUTH-9230 --preqs-met ${PREQS_MET} --root-only NO --weight L --network NO --category security --description "Check group password hashing rounds" if [ ${SKIPTEST} -eq 0 ]; then LogText "Test: Checking SHA_CRYPT_MIN_ROUNDS option in ${ROOTDIR}etc/login.defs" FIND=$(${GREPBINARY} "^SHA_CRYPT_MIN_ROUNDS" ${ROOTDIR}etc/login.defs | ${AWKBINARY} '{ if ($1=="SHA_CRYPT_MIN_ROUNDS") { print $2 } }')