# Create an initial sample configuration (required by 'make ... install'
# below). This one is probably most appropriate to be run locally and from
# cron periodically. For more info about what to put in here, see the two
# samples in ./conf/ and look at the ./README
cat > conf/syscheck.config <<EOF
term = n
syslog = y
daemon = n
chkdir = /sbin/,/bin/,/etc/,/usr/local/sbin/,/usr/local/bin/
EOF
# Become root to install and configure it
su
make -f Makefile.example install
# Create the database:
/usr/local/syscheck/syscheck start
# Check files on your system against the database:
/usr/local/syscheck/syscheck
# If you want to keep the database on a remote (secure) server, modify the
# config file (/usr/local/syscheck/syscheck.config) to look like
# conf/syscheck-remote.config in the source. scp the config file to the
# remote server, then syscheck will read it remotely. See the source's
# README for more info.
# You can run it by hand, run it from cron, or have it run as a daemon
# (see the config file).
# To set up an hourly cron job (if you have the
# /etc/cron.(hourly|daily|weekly|monthly directories set up):
echo '#!/bin/sh' > /etc/cron.hourly/syscheck.sh
echo '/usr/local/syscheck/syscheck' >> /etc/cron.hourly/syscheck.sh
chmod 700 /etc/cron.hourly/syscheck.sh