summaryrefslogtreecommitdiffstats
path: root/etc/security
diff options
context:
space:
mode:
authorphantom <phantom@FreeBSD.org>1999-12-20 17:33:56 +0000
committerphantom <phantom@FreeBSD.org>1999-12-20 17:33:56 +0000
commitc243ab1306be7ec071bb9198d9a7691444f6355e (patch)
tree018bec030a56bd9fbeb8f4703840e2c874e8c6ff /etc/security
parent8c8dba944b6ffd0a7055b65b49bd35873512625f (diff)
downloadFreeBSD-src-c243ab1306be7ec071bb9198d9a7691444f6355e.zip
FreeBSD-src-c243ab1306be7ec071bb9198d9a7691444f6355e.tar.gz
Test rotated logs for dangerous messages as well as current
PR: misc/12228 Submitted by: Philippe SCHACK <phschak@inba.fr>
Diffstat (limited to 'etc/security')
-rw-r--r--etc/security6
1 files changed, 4 insertions, 2 deletions
diff --git a/etc/security b/etc/security
index 7570cd1..96ffc28 100644
--- a/etc/security
+++ b/etc/security
@@ -11,6 +11,8 @@ separator () {
echo ''
}
+yesterday=`date -v-1d "+%b %e "`
+
host=`hostname`
echo "Subject: ${host} security check output"
@@ -110,12 +112,12 @@ fi
#
separator
echo "${host} login failures:"
-grep -i "login failure" ${LOG}/messages
+zcat -f $LOG/messages.0* $LOG/messages | grep -i "^$yesterday.*login failure"
# Show tcp_wrapper warning messages
#
separator
echo "${host} refused connections:"
-grep -i "refused connect" ${LOG}/messages
+zcat -f $LOG/messages.0* $LOG/messages | grep -i "^$yesterday.*refused connect"
rm -f ${TMP}
OpenPOWER on IntegriCloud