mirror of https://github.com/CISOfy/lynis.git
[TIME-3104] added more logging
This commit is contained in:
parent
166f5f92c9
commit
f8697db25b
|
@ -102,14 +102,19 @@
|
|||
FIND=$(${TIMEDATECTL} status | ${EGREPBINARY} "(NTP|System clock) synchronized: yes")
|
||||
if [ ! -z "${FIND}" ]; then
|
||||
# Check for systemd-timesyncd
|
||||
if [ -f /etc/systemd/timesyncd.conf ]; then
|
||||
if [ -f ${ROOTDIR}etc/systemd/timesyncd.conf ]; then
|
||||
LogText "Result: found ${ROOTDIR}etc/systemd/timesyncd.conf"
|
||||
FOUND=1; NTP_DAEMON_RUNNING=1; NTP_CONFIG_TYPE_DAEMON=1; NTP_DAEMON="systemd-timesyncd"
|
||||
Display --indent 2 --text "- NTP daemon found: systemd (timesyncd)" --result "${STATUS_FOUND}" --color GREEN
|
||||
SYSTEMD_NTP_ENABLED=1
|
||||
else
|
||||
LogText "Result: ${ROOTDIR}etc/systemd/timesyncd.conf does not exist"
|
||||
fi
|
||||
else
|
||||
LogText "Result: time sychronization not performed according timedatectl command"
|
||||
fi
|
||||
else
|
||||
LogText "Result: timedatectl command not available on this system"
|
||||
fi
|
||||
|
||||
# Check crontab for OpenBSD/FreeBSD
|
||||
|
|
Loading…
Reference in New Issue