mirror of
https://github.com/CISOfy/lynis.git
synced 2025-07-28 16:24:13 +02:00
Check for number of arguments
This commit is contained in:
parent
f498d7bf2c
commit
db5d825701
@ -33,7 +33,7 @@
|
|||||||
HELPER="audit"
|
HELPER="audit"
|
||||||
SKIP_PLUGINS=1
|
SKIP_PLUGINS=1
|
||||||
RUN_TESTS=0
|
RUN_TESTS=0
|
||||||
if [ ! $2 = "" ]; then
|
if [ $# -gt 1 ]; then
|
||||||
case $2 in
|
case $2 in
|
||||||
"dockerfile")
|
"dockerfile")
|
||||||
if [ "$3" = "" ]; then
|
if [ "$3" = "" ]; then
|
||||||
@ -48,6 +48,7 @@
|
|||||||
fi
|
fi
|
||||||
;;
|
;;
|
||||||
"system")
|
"system")
|
||||||
|
if [ $# -gt 2 ]; then
|
||||||
if [ "$3" = "remote" ]; then
|
if [ "$3" = "remote" ]; then
|
||||||
shift
|
shift
|
||||||
if [ "$3" = "" ]; then
|
if [ "$3" = "" ]; then
|
||||||
@ -77,12 +78,14 @@
|
|||||||
break
|
break
|
||||||
fi
|
fi
|
||||||
fi
|
fi
|
||||||
|
fi
|
||||||
CHECK=1
|
CHECK=1
|
||||||
CHECK_BINARIES=1
|
CHECK_BINARIES=1
|
||||||
HELPER=""
|
HELPER=""
|
||||||
SKIP_PLUGINS=0
|
SKIP_PLUGINS=0
|
||||||
RUN_TESTS=1
|
RUN_TESTS=1
|
||||||
shift
|
shift
|
||||||
|
|
||||||
;;
|
;;
|
||||||
esac
|
esac
|
||||||
else
|
else
|
||||||
|
Loading…
x
Reference in New Issue
Block a user