mirror of
https://github.com/CISOfy/lynis.git
synced 2025-07-22 21:34:38 +02:00
Added warning when log is empty in pentest mode
This commit is contained in:
parent
47678ffeaa
commit
abcf438ee1
22
lynis
22
lynis
@ -156,7 +156,9 @@
|
|||||||
|
|
||||||
# Disable logging if no alternative was provided
|
# Disable logging if no alternative was provided
|
||||||
if [ ${PENTESTINGMODE} -eq 1 ]; then
|
if [ ${PENTESTINGMODE} -eq 1 ]; then
|
||||||
if [ "${LOGFILE}" = "" ]; then LOGFILE="/dev/null"; fi
|
if [ "${LOGFILE}" = "" ]; then
|
||||||
|
LOGFILE="/dev/null"
|
||||||
|
fi
|
||||||
if [ "${REPORTFILE}" = "" ]; then REPORTFILE="/dev/null"; fi
|
if [ "${REPORTFILE}" = "" ]; then REPORTFILE="/dev/null"; fi
|
||||||
fi
|
fi
|
||||||
#
|
#
|
||||||
@ -280,18 +282,26 @@
|
|||||||
fi
|
fi
|
||||||
|
|
||||||
if [ ${PENTESTINGMODE} -eq 1 ]; then
|
if [ ${PENTESTINGMODE} -eq 1 ]; then
|
||||||
|
echo ""; echo ""
|
||||||
echo "${WHITE}"
|
echo "${WHITE}"
|
||||||
echo " #########################################################"
|
echo " #########################################################"
|
||||||
|
echo " # #"
|
||||||
echo " # ${PURPLE}Pentesting mode (non-privileged)${WHITE} #"
|
echo " # ${PURPLE}Pentesting mode (non-privileged)${WHITE} #"
|
||||||
|
echo " # #"
|
||||||
echo " #########################################################"
|
echo " #########################################################"
|
||||||
echo "${NORMAL}"
|
echo "${NORMAL}"
|
||||||
echo " ${CYAN}NOTES:${NORMAL}"
|
echo " ${YELLOW}NOTES:${NORMAL}"
|
||||||
echo " --------------"
|
echo " --------------"
|
||||||
echo " ${RED}*${NORMAL} Some tests will be skipped (requires root permissions)"
|
echo " ${WHITE}*${NORMAL} This mode is suitable for pentests only (not full audit)"
|
||||||
echo " ${RED}*${NORMAL} Some tests might fail silently or give different results"
|
echo " ${WHITE}*${NORMAL} Some tests will be skipped (as they require root permissions)"
|
||||||
echo " ${RED}*${NORMAL} This mode is preferred for pentests only (not full audit)"
|
echo " ${WHITE}*${NORMAL} Some tests might fail silently or give different results"
|
||||||
echo " ${RED}*${NORMAL} Logging capabilities might be limited"
|
|
||||||
echo ""
|
echo ""
|
||||||
|
if [ "${LOGFILE}" = "" -o "${LOGFILE}" = "/dev/null" ]; then
|
||||||
|
echo " ${RED}Warning:${NORMAL}"
|
||||||
|
echo " ${WHITE}*${NORMAL} No suggestions or warnings will be displayed in report"
|
||||||
|
echo " (Reason is missing log file)"
|
||||||
|
echo ""
|
||||||
|
fi
|
||||||
echo " ${WHITE}Press [ENTER] to continue or [CTRL] + C to break${NORMAL}"
|
echo " ${WHITE}Press [ENTER] to continue or [CTRL] + C to break${NORMAL}"
|
||||||
echo ""
|
echo ""
|
||||||
echo " #########################################################"
|
echo " #########################################################"
|
||||||
|
Loading…
x
Reference in New Issue
Block a user