
150 Chapter 12. Installing and Configuring Tripwire
1. If you already know of several changes that should be made to the configuration file
(/etc/tripwire/twcfg.txt) or the policy file (/etc/tripwire/twpol.txt), edit those
files now.
Note
While you should edit your configuration and policy files to customize Tripwire to your particu-
lar situation, editing the configuration or policy files is not required to use Tripwire. If you plan
to modify the configuration or policy files, you must make these changes before running the
configuration script (/etc/tripwire/twinstall.sh). If you modify the configuration or policy
files after running the configuration script, you must re-run the configuration script before ini-
tializing the database file. Keep in mind that you can edit the configuration and policy files after
initializing the database file and running an integrity check.
2. Type /etc/tripwire/twinstall.sh at the command line as root and press [Enter] to run
the configuration script. The twinstall.sh script walks you through the processes of setting
passphrases, generating the cryptographic keys that protect the Tripwire configuration and pol-
icy files, and signing these files. See Section 12.6 for more information on setting passphrases.
Note
Once encoded and signed, the configuration file (/etc/tripwire/tw.cfg) and policy file
(/etc/tripwire/tw.pol) generated by running the /etc/tripwire/twinstall.sh script
should not be renamed or moved.
3. Initialize the Tripwire database file by issuing the /usr/sbin/tripwire --init command
at the command line.
4. Run the first integrity check comparing your new Tripwire database to your system files by
issuing the /usr/sbin/tripwire --check command at the command line and looking for
errors in the generated report.
Once you finish these steps successfully, Tripwire has the baseline snapshot of your filesystem that
it needs to check for changes to critical files. Additionally, the tripwire RPM adds a file called
tripwire-check to the /etc/cron.daily directory that will automatically run an integrity check
once per day.
12.3. File Locations
Before working with Tripwire, you should know where important files for the application are located.
Tripwire stores its files in a variety of places depending on their role:
• The /usr/sbin directory stores the tripwire, twadmin, and twprint programs.
• The /etc/tripwire directory contains the local and site keys (*.key files) and the initialization
script (twinstall.sh), as well as the sample and actual configuration and policy files.
• The /var/lib/tripwire directory contains the Tripwire database of your system’s files
(*.twd) and a report directory where Tripwire reports are stored. The Tripwire reports, named
host_name-date_of_report-time_of_report.twr, detail the differences between the
Tripwire database and your actual system files.
Commenti su questo manuale