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:
authoralobodzinski <lobo@dzinski.net>2017-02-21 17:25:48 +0300
committerMichael Boelen <michael.boelen@cisofy.com>2017-02-21 17:25:48 +0300
commit08b6a40751f6f69caeeda385740d5c3a42f220a9 (patch)
tree82d7065e67626c93c904afb3660f451227d2fb05 /include/tests_mail_messaging
parent6bb3c77a694afa530b86b0a5ba5757740cc50ac3 (diff)
MAIL-8818: $LINUX_VERSION is not set on every OS (#357)
Diffstat (limited to 'include/tests_mail_messaging')
-rw-r--r--include/tests_mail_messaging8
1 files changed, 7 insertions, 1 deletions
diff --git a/include/tests_mail_messaging b/include/tests_mail_messaging
index aae8b1f2..2c9a2d66 100644
--- a/include/tests_mail_messaging
+++ b/include/tests_mail_messaging
@@ -101,7 +101,10 @@
FIND1=$(${POSTCONFBINARY} 2> /dev/null | ${GREPBINARY} '^smtpd_banner' | ${GREPBINARY} 'postfix')
FIND2=$(${POSTCONFBINARY} 2> /dev/null | ${GREPBINARY} '^smtpd_banner' | ${GREPBINARY} '$mail_name')
FIND3=$(${POSTCONFBINARY} 2> /dev/null | ${GREPBINARY} '^mail_name' | ${GREPBINARY} -i 'postfix')
- FIND4=$(${POSTCONFBINARY} 2> /dev/null | ${GREPBINARY} '^smtpd_banner' | ${EGREPBINARY} -i "${OS}|${LINUX_VERSION}")
+ FIND4=$(${POSTCONFBINARY} 2> /dev/null | ${GREPBINARY} '^smtpd_banner' | ${GREPBINARY} -i "${OS}")
+ if [ ! -z "${LINUX_VERSION}" ]; then
+ FIND5=$(${POSTCONFBINARY} 2> /dev/null | ${GREPBINARY} '^smtpd_banner' | ${GREPBINARY} -i "${LINUX_VERSION}")
+ fi
SHOWWARNING=0
if [ ! -z "${FIND1}" ]; then
@@ -113,6 +116,9 @@
elif [ ! -z "${FIND4}" ]; then
SHOWWARNING=1
Report "banner_os_disclosure[]=${FIND4}"
+ elif [ ! -z "${FIND5}" ]; then
+ SHOWWARNING=1
+ Report "banner_os_disclosure[]=${FIND5}"
fi
if [ ${SHOWWARNING} -eq 1 ]; then