Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/CISOfy/lynis.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMichael Boelen <michael.boelen@cisofy.com>2020-03-19 12:51:02 +0300
committerMichael Boelen <michael.boelen@cisofy.com>2020-03-19 12:51:02 +0300
commitbc4146555ceaaf03c924ef9263050d8caee2f580 (patch)
tree4d6d5d7fa1608ca16d9d0cddc0d5d3c9b6062593 /include/tests_ports_packages
parentcc78713c6a989d974d4403653d0d3f46f51c7882 (diff)
[PKGS-7388] Only perform test when all conditions are correct
Diffstat (limited to 'include/tests_ports_packages')
-rw-r--r--include/tests_ports_packages10
1 files changed, 6 insertions, 4 deletions
diff --git a/include/tests_ports_packages b/include/tests_ports_packages
index f2291a03..484607e4 100644
--- a/include/tests_ports_packages
+++ b/include/tests_ports_packages
@@ -982,17 +982,19 @@
#################################################################################
#
# Test : PKGS-7388
- # Description : Check security repository in Debian/ubuntu apt sources.list file
+ # Description : Check security repository in Debian/Ubuntu apt sources.list file
+ PREQS_MET="NO"
if [ -f ${ROOTDIR}etc/apt/sources.list -a -d ${ROOTDIR}etc/apt/sources.list.d ]; then
case "${LINUX_VERSION}" in
- "Debian" | "Linux Mint" | "Ubuntu") PREQS_MET="YES" ;;
+ "Debian" | "Linux Mint" | "Ubuntu")
+ PREQS_MET="YES"
+ ;;
*)
- PREQS_MET="NO"
LogText "Skipping test, although sources.list or sources.list.d exists. This specific OS version most likely has no security repository"
;;
esac
fi
- Register --test-no PKGS-7388 --preqs-met ${PREQS_MET} --weight L --network NO --category security --description "Check security repository in Debian/ubuntu apt sources.list file"
+ Register --test-no PKGS-7388 --preqs-met ${PREQS_MET} --weight L --network NO --category security --description "Check security repository in apt sources.list file"
if [ $SKIPTEST -eq 0 ]; then
FOUND=0
if [ ${OPTION_DEBIAN_SKIP_SECURITY_REPOSITORY} -eq 0 ]; then