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:
authormboelen <michael@cisofy.com>2015-03-05 00:46:40 +0300
committermboelen <michael@cisofy.com>2015-03-05 00:46:40 +0300
commit215ed82899bcfef854defb594c1c75bfa61bd250 (patch)
tree89668d1aab6a9d28d25934f6abb7346cd5c7aa08
parent98c9f2e3bcf41d07c2740af24ba683a6abec1102 (diff)
Check if default profile can be found
-rwxr-xr-xlynis7
1 files changed, 6 insertions, 1 deletions
diff --git a/lynis b/lynis
index b2925d38..06992e34 100755
--- a/lynis
+++ b/lynis
@@ -22,7 +22,7 @@
#
# Program information
PROGRAM_name="Lynis"
- PROGRAM_version="2.0.0"
+ PROGRAM_version="2.1.0"
PROGRAM_releasedate="25 February 2015"
PROGRAM_author="CISOfy"
PROGRAM_author_contact="lynis-dev@cisofy.com"
@@ -287,6 +287,11 @@
if [ -f ${I} ]; then PROFILE=${I}; fi
done
fi
+ if [ "${PROFILE}" = "" ]; then
+ echo "${RED}Fatal error: ${WHITE}No profile defined and could not find default profile${NORMAL}"
+ echo "Search paths used --> ${tPROFILE_TARGETS}"
+ ExitFatal
+ fi
# Initialize and check profile file, auditor name, log file and report file
if [ ! -r ${PROFILE} ]; then echo "Fatal error: Can't open profile file (${PROFILE})"; exit 1; fi
if [ "${AUDITORNAME}" = "" ]; then AUDITORNAME="[Unknown]"; fi