SOURCES: tripwire.verify - for 2.4.1.2

wolvverine wolvverine at pld-linux.org
Tue Sep 4 21:23:55 CEST 2007


Author: wolvverine                   Date: Tue Sep  4 19:23:55 2007 GMT
Module: SOURCES                       Tag: HEAD
---- Log message:
- for 2.4.1.2

---- Files affected:
SOURCES:
   tripwire.verify (1.1 -> 1.2) 

---- Diffs:

================================================================
Index: SOURCES/tripwire.verify
diff -u SOURCES/tripwire.verify:1.1 SOURCES/tripwire.verify:1.2
--- SOURCES/tripwire.verify:1.1	Sun May 14 14:40:19 2000
+++ SOURCES/tripwire.verify	Tue Sep  4 21:23:49 2007
@@ -1,17 +1,36 @@
 #!/bin/sh
-/usr/sbin/tripwire -loosedir -q | (cat <<EOF
-This is an automated report of possible file integrity changes, generated by
-the Tripwire integrity checker. To tell Tripwire that a file or entire
-directory tree is valid, as root run:
-
-/usr/sbin/tripwire -update [pathname|entry]
-
-If you wish to enter an interactive integrity checking and verification
-session, as root run:
-
-/usr/sbin/tripwire -interactive
-
-Changed files/directories include:
-EOF
-cat
-) | /bin/mail -s "File integrity report" root
+
+HOST_NAME=`uname -n`
+TWCFG_PATH=/etc/tripwire
+TWDB_PATH=/usr/lib/tripwire
+TWROOT_PATH=/usr/sbin
+MAILTO="root"           # Email addresses that should recieve reports
+
+
+#
+#  Define checks which alert user to misconfiguration or run the check
+#
+if [ ! -e ${TWDB_PATH}/${HOST_NAME}.twd ]; then
+	echo "****   Error: Tripwire database for ${HOST_NAME} not found.  ****"
+	echo "****  Verify tripwire was installed and/or "tripwire --init".  ****"
+	mail -s "****   Error: Tripwire database for ${HOST_NAME} not found." ${MAILTO}
+else
+	(cat <<EOF
+	This is an automated report of possible file integrity changes, generated by
+	the Tripwire integrity checker. To tell Tripwire that a file or entire
+	directory tree is valid, as root run:
+
+	/usr/sbin/tripwire -update [pathname|entry]
+
+	If you wish to enter an interactive integrity checking and verification
+	session, as root run:
+
+	/usr/sbin/tripwire 
+
+	Changed files/directories include:
+	EOF
+	cat
+	) | test -f ${TWCFG_PATH}/tw.cfg && ${TWROOT_PATH}/tripwire --check | \
+	mail -s "${HOST_NAME} tripwire-check. File integrity report" ${MAILTO}
+fi
+
================================================================

---- CVS-web:
    http://cvs.pld-linux.org/cgi-bin/cvsweb.cgi/SOURCES/tripwire.verify?r1=1.1&r2=1.2&f=u



More information about the pld-cvs-commit mailing list