[b4b71892] | 1 | <?xml version="1.0" encoding="ISO-8859-1"?>
|
---|
[ff769b8c] | 2 | <!DOCTYPE sect1 PUBLIC "-//OASIS//DTD DocBook XML V4.4//EN"
|
---|
| 3 | "http://www.oasis-open.org/docbook/xml/4.4/docbookx.dtd" [
|
---|
[b4b71892] | 4 | <!ENTITY % general-entities SYSTEM "../../general.ent">
|
---|
| 5 | %general-entities;
|
---|
| 6 |
|
---|
[dc94017e] | 7 | <!ENTITY tripwire-download-http "http://www.frenchfries.net/paul/tripwire/tripwire-&tripwire-version;.tar.gz">
|
---|
| 8 | <!ENTITY tripwire-download-ftp " ">
|
---|
[fb5327d] | 9 | <!ENTITY tripwire-md5sum "02610d0593fe04d35d809ff6c5becc02">
|
---|
[dc94017e] | 10 | <!ENTITY tripwire-size "869 KB">
|
---|
| 11 | <!ENTITY tripwire-buildsize "22 MB">
|
---|
| 12 | <!ENTITY tripwire-time "2.96 SBU">
|
---|
[b4b71892] | 13 | ]>
|
---|
| 14 |
|
---|
[dc94017e] | 15 | <sect1 id="tripwire-portable" xreflabel="Tripwire-&tripwire-version;">
|
---|
[1503942] | 16 | <?dbhtml filename="tripwire.html"?>
|
---|
| 17 |
|
---|
| 18 | <sect1info>
|
---|
| 19 | <othername>$LastChangedBy$</othername>
|
---|
| 20 | <date>$Date$</date>
|
---|
[e19ad480] | 21 | <keywordset>
|
---|
| 22 | <keyword role="package">tripwire-&tripwire-version;.tar</keyword>
|
---|
[9084c2eb] | 23 | <keyword role="ftpdir">tripwire</keyword>
|
---|
[e19ad480] | 24 | </keywordset>
|
---|
[1503942] | 25 | </sect1info>
|
---|
| 26 |
|
---|
| 27 | <title>Tripwire-&tripwire-version;</title>
|
---|
| 28 |
|
---|
| 29 | <indexterm zone="tripwire-portable">
|
---|
| 30 | <primary sortas="a-Tripwire">Tripwire</primary>
|
---|
| 31 | </indexterm>
|
---|
| 32 |
|
---|
| 33 | <sect2 role="package">
|
---|
| 34 | <title>Introduction to Tripwire</title>
|
---|
| 35 |
|
---|
| 36 | <para>The <application>Tripwire</application> package contains programs
|
---|
| 37 | used to verify the integrity of the files on a given system.</para>
|
---|
| 38 |
|
---|
| 39 | <bridgehead renderas="sect3">Package Information</bridgehead>
|
---|
| 40 | <itemizedlist spacing="compact">
|
---|
| 41 | <listitem>
|
---|
| 42 | <para>Download (HTTP): <ulink url="&tripwire-download-http;"/></para>
|
---|
| 43 | </listitem>
|
---|
| 44 | <listitem>
|
---|
| 45 | <para>Download (FTP): <ulink url="&tripwire-download-ftp;"/></para>
|
---|
| 46 | </listitem>
|
---|
| 47 | <listitem>
|
---|
| 48 | <para>Download MD5 sum: &tripwire-md5sum;</para>
|
---|
| 49 | </listitem>
|
---|
| 50 | <listitem>
|
---|
| 51 | <para>Download size: &tripwire-size;</para>
|
---|
| 52 | </listitem>
|
---|
| 53 | <listitem>
|
---|
| 54 | <para>Estimated disk space required: &tripwire-buildsize;</para>
|
---|
| 55 | </listitem>
|
---|
| 56 | <listitem>
|
---|
| 57 | <para>Estimated build time: &tripwire-time;</para>
|
---|
| 58 | </listitem>
|
---|
| 59 | </itemizedlist>
|
---|
| 60 |
|
---|
| 61 | <bridgehead renderas="sect3">Tripwire Dependencies</bridgehead>
|
---|
| 62 |
|
---|
| 63 | <bridgehead renderas="sect4">Optional</bridgehead>
|
---|
[e19ad480] | 64 | <para role="optional">MTA (See <xref linkend="server-mail"/>)</para>
|
---|
[1503942] | 65 |
|
---|
| 66 | </sect2>
|
---|
| 67 |
|
---|
| 68 | <sect2 role="installation">
|
---|
| 69 | <title>Installation of Tripwire</title>
|
---|
| 70 |
|
---|
| 71 | <para>Compile <application>Tripwire</application> by running the following
|
---|
| 72 | commands:</para>
|
---|
| 73 |
|
---|
| 74 | <screen><userinput>sed -i -e 's@TWDB="${prefix}@TWDB="/var@' install/install.cfg &&
|
---|
[dc94017e] | 75 | ./configure --prefix=/usr --sysconfdir=/etc/tripwire &&
|
---|
[1503942] | 76 | make</userinput></screen>
|
---|
[305e60de] | 77 |
|
---|
[1503942] | 78 | <para>Now, as the <systemitem class="username">root</systemitem> user:</para>
|
---|
[305e60de] | 79 |
|
---|
[1503942] | 80 | <screen role="root"><userinput>make install &&
|
---|
| 81 | cp -v policy/*.txt /usr/share/doc/tripwire</userinput></screen>
|
---|
[b4b71892] | 82 |
|
---|
[1503942] | 83 | <para>The default configuration is to use a local MTA. If
|
---|
| 84 | you don't have an MTA installed and have no wish to install
|
---|
| 85 | one, modify <filename>install.cfg</filename> to use an SMTP
|
---|
| 86 | server instead.</para>
|
---|
[b4b71892] | 87 |
|
---|
[1503942] | 88 | </sect2>
|
---|
[b4b71892] | 89 |
|
---|
[1503942] | 90 | <sect2 role="commands">
|
---|
| 91 | <title>Command Explanations</title>
|
---|
[b4b71892] | 92 |
|
---|
[1503942] | 93 | <para><command>sed -i -e 's@TWDB="${prefix}@TWDB="/var@'
|
---|
| 94 | install/install.cfg</command>: This command tells the package to install
|
---|
| 95 | the program database and reports in
|
---|
| 96 | <filename class="directory">/var/lib/tripwire</filename>.</para>
|
---|
[b4b71892] | 97 |
|
---|
[1503942] | 98 | <para><command>make install</command>: This command creates the
|
---|
| 99 | <application>Tripwire</application> security keys as well as installing
|
---|
| 100 | the binaries. There are two keys: a site key and a local key which are
|
---|
| 101 | stored in <filename class="directory">/etc/tripwire/</filename>.</para>
|
---|
[b4b71892] | 102 |
|
---|
[1503942] | 103 | <para><command>cp -v policy/*.txt /usr/share/doc/tripwire</command>: This
|
---|
| 104 | command installs the documentation.</para>
|
---|
[b4b71892] | 105 |
|
---|
[1503942] | 106 | </sect2>
|
---|
[b4b71892] | 107 |
|
---|
[1503942] | 108 | <sect2 role="configuration">
|
---|
| 109 | <title>Configuring Tripwire</title>
|
---|
[b4b71892] | 110 |
|
---|
[1503942] | 111 | <sect3 id="tripwire-config">
|
---|
| 112 | <title>Config Files</title>
|
---|
[b4b71892] | 113 |
|
---|
[1503942] | 114 | <para><filename>/etc/tripwire/*</filename></para>
|
---|
[b4b71892] | 115 |
|
---|
[1503942] | 116 | <indexterm zone="tripwire-portable tripwire-config">
|
---|
| 117 | <primary sortas="e-etc-tripwire">/etc/tripwire/*</primary>
|
---|
| 118 | </indexterm>
|
---|
[b4b71892] | 119 |
|
---|
[1503942] | 120 | </sect3>
|
---|
[e40cb61] | 121 |
|
---|
[1503942] | 122 | <sect3>
|
---|
| 123 | <title>Configuration Information</title>
|
---|
| 124 |
|
---|
| 125 | <para><application>Tripwire</application> uses a policy file to
|
---|
| 126 | determine which files are integrity checked. The default policy
|
---|
| 127 | file (<filename>/etc/tripwire/twpol.txt</filename>) is for a
|
---|
[0bc6cf76] | 128 | default Redhat installation and will need to be updated for your
|
---|
[1503942] | 129 | system.</para>
|
---|
| 130 |
|
---|
| 131 | <para>Policy files should be tailored to each individual distribution
|
---|
| 132 | and/or installation. Some custom policy files can be found below:</para>
|
---|
| 133 |
|
---|
| 134 | <literallayout><ulink url="http://home.iprimus.com.au/glombowski/blfs/twpol-all.txt"/>
|
---|
[b4b71892] | 135 | Checks integrity of all files
|
---|
[e40cb61] | 136 | <ulink url="http://home.iprimus.com.au/glombowski/blfs/twpol-lfs.txt"/>
|
---|
[b4b71892] | 137 | Custom policy file for Base LFS 3.0 system
|
---|
[e40cb61] | 138 | <ulink url="http://home.iprimus.com.au/glombowski/blfs/twpol-suse7.2.txt"/>
|
---|
[1503942] | 139 | Custom policy file for SuSE 7.2 system</literallayout>
|
---|
| 140 |
|
---|
| 141 | <para>Download the custom policy file you'd like to try, copy it into
|
---|
| 142 | <filename class="directory">/etc/tripwire/</filename>, and use it instead
|
---|
| 143 | of <filename>twpol.txt</filename>. It is, however, recommended that you
|
---|
| 144 | make your own policy file. Get ideas from the examples above and read
|
---|
| 145 | <filename>/usr/share/doc/tripwire/policyguide.txt</filename> for
|
---|
| 146 | additional information. <filename>twpol.txt</filename> is a good policy
|
---|
| 147 | file for beginners as it will note any changes to the file system and can
|
---|
| 148 | even be used as an annoying way of keeping track of changes for
|
---|
| 149 | uninstallation of software.</para>
|
---|
| 150 |
|
---|
| 151 | <para>After your policy file has been transferred to
|
---|
| 152 | <filename class="directory">/etc/tripwire/</filename> you may begin
|
---|
[0bc6cf76] | 153 | the configuration steps (perform as the
|
---|
| 154 | <systemitem class='username'>root</systemitem>):</para>
|
---|
[1503942] | 155 |
|
---|
| 156 | <screen role="root"><userinput>twadmin --create-polfile --site-keyfile /etc/tripwire/site.key \
|
---|
[dd362e5] | 157 | /etc/tripwire/twpol.txt &&
|
---|
[1503942] | 158 | tripwire --init</userinput></screen>
|
---|
| 159 |
|
---|
| 160 | </sect3>
|
---|
| 161 |
|
---|
| 162 | <sect3>
|
---|
| 163 | <title>Usage Information</title>
|
---|
| 164 |
|
---|
| 165 | <para>To use <application>Tripwire</application> after creating a policy
|
---|
| 166 | file to run a report, use the following command:</para>
|
---|
| 167 |
|
---|
| 168 | <screen role="root"><userinput>tripwire --check > /etc/tripwire/report.txt</userinput></screen>
|
---|
| 169 |
|
---|
| 170 | <para>View the output to check the integrity of your files. An automatic
|
---|
| 171 | integrity report can be produced by using a cron facility to schedule
|
---|
| 172 | the runs.</para>
|
---|
| 173 |
|
---|
| 174 | <para>Please note that after you run an integrity check, you must
|
---|
| 175 | examine the report (or email) and then modify the
|
---|
| 176 | <application>Tripwire</application> database to reflect the changed
|
---|
| 177 | files on your system. This is so that <application>Tripwire</application>
|
---|
| 178 | will not continually notify you that files you intentionally changed are
|
---|
| 179 | a security violation. To do this you must first <command>ls -l
|
---|
| 180 | /var/lib/tripwire/report/</command> and note the name of the newest file
|
---|
| 181 | which starts with <filename>linux-</filename> and ends in
|
---|
| 182 | <filename>.twr</filename>. This encrypted file was created during the
|
---|
| 183 | last report creation and is needed to update the
|
---|
[0bc6cf76] | 184 | <application>Tripwire</application> database of your system. Then, as the
|
---|
| 185 | <systemitem class='username'>root</systemitem> user, type
|
---|
[1503942] | 186 | in the following command making the appropriate substitutions for
|
---|
| 187 | <replaceable>[?]</replaceable>:</para>
|
---|
| 188 |
|
---|
| 189 | <screen role="root"><userinput>tripwire --update -twrfile \
|
---|
| 190 | /var/lib/tripwire/report/linux-<replaceable>[???????]</replaceable>-<replaceable>[??????]</replaceable>.twr</userinput></screen>
|
---|
| 191 |
|
---|
| 192 | <para>You will be placed into <application>vim</application> with a copy
|
---|
| 193 | of the report in front of you. If all the changes were good, then just
|
---|
| 194 | type <command>:x</command> and after entering your local key, the database
|
---|
| 195 | will be updated. If there are files which you still want to be warned
|
---|
| 196 | about, remove the 'x' before the filename in the report and type
|
---|
| 197 | <command>:x</command>.</para>
|
---|
| 198 |
|
---|
| 199 | </sect3>
|
---|
| 200 |
|
---|
| 201 | <sect3>
|
---|
| 202 | <title>Changing the Policy File</title>
|
---|
| 203 |
|
---|
| 204 | <para>If you are unhappy with your policy file and would like to modify
|
---|
| 205 | it or use a new one, modify the policy file and then execute the following
|
---|
[0bc6cf76] | 206 | commands as the <systemitem class='username'>root</systemitem> user:</para>
|
---|
[1503942] | 207 |
|
---|
| 208 | <screen role="root"><userinput>twadmin --create-polfile /etc/tripwire/twpol.txt &&
|
---|
| 209 | tripwire --init</userinput></screen>
|
---|
| 210 |
|
---|
| 211 | </sect3>
|
---|
| 212 |
|
---|
| 213 | </sect2>
|
---|
| 214 |
|
---|
| 215 | <sect2 role="content">
|
---|
| 216 | <title>Contents</title>
|
---|
| 217 |
|
---|
| 218 | <segmentedlist>
|
---|
| 219 | <segtitle>Installed Programs</segtitle>
|
---|
| 220 | <segtitle>Installed Libraries</segtitle>
|
---|
| 221 | <segtitle>Installed Directories</segtitle>
|
---|
| 222 |
|
---|
| 223 | <seglistitem>
|
---|
| 224 | <seg>siggen, tripwire, twadmin, and twprint.</seg>
|
---|
| 225 | <seg>None</seg>
|
---|
| 226 | <seg>/etc/tripwire, /usr/share/doc/tripwire, and /var/lib/tripwire</seg>
|
---|
| 227 | </seglistitem>
|
---|
| 228 | </segmentedlist>
|
---|
| 229 |
|
---|
| 230 | <variablelist>
|
---|
| 231 | <bridgehead renderas="sect3">Short Descriptions</bridgehead>
|
---|
| 232 | <?dbfo list-presentation="list"?>
|
---|
| 233 | <?dbhtml list-presentation="table"?>
|
---|
| 234 |
|
---|
| 235 | <varlistentry id="siggen">
|
---|
| 236 | <term><command>siggen</command></term>
|
---|
| 237 | <listitem>
|
---|
| 238 | <para>is a signature gathering utility that displays
|
---|
| 239 | the hash function values for the specified files.</para>
|
---|
| 240 | <indexterm zone="tripwire-portable siggen">
|
---|
| 241 | <primary sortas="b-siggen">siggen</primary>
|
---|
| 242 | </indexterm>
|
---|
| 243 | </listitem>
|
---|
| 244 | </varlistentry>
|
---|
| 245 |
|
---|
| 246 | <varlistentry id='tripwire'>
|
---|
| 247 | <term><command>tripwire</command></term>
|
---|
| 248 | <listitem>
|
---|
| 249 | <para>is the main file integrity checking program.</para>
|
---|
| 250 | <indexterm zone="tripwire-portable tripwire">
|
---|
| 251 | <primary sortas="b-tripwire">tripwire</primary>
|
---|
| 252 | </indexterm>
|
---|
| 253 | </listitem>
|
---|
| 254 | </varlistentry>
|
---|
| 255 |
|
---|
| 256 | <varlistentry id='twadmin'>
|
---|
| 257 | <term><command>twadmin</command></term>
|
---|
| 258 | <listitem>
|
---|
| 259 | <para>administrative and utility tool used to perform
|
---|
| 260 | certain administrative functions related to
|
---|
| 261 | <application>Tripwire</application> files and configuration
|
---|
| 262 | options.</para>
|
---|
| 263 | <indexterm zone="tripwire-portable twadmin">
|
---|
| 264 | <primary sortas="b-twadmin">twadmin</primary>
|
---|
| 265 | </indexterm>
|
---|
| 266 | </listitem>
|
---|
| 267 | </varlistentry>
|
---|
| 268 |
|
---|
| 269 | <varlistentry id='twprint'>
|
---|
| 270 | <term><command>twprint</command></term>
|
---|
| 271 | <listitem>
|
---|
| 272 | <para>prints <application>Tripwire</application>
|
---|
| 273 | database and report files in clear text format.</para>
|
---|
| 274 | <indexterm zone="tripwire-portable twprint">
|
---|
| 275 | <primary sortas="b-twprint">twprint</primary>
|
---|
| 276 | </indexterm>
|
---|
| 277 | </listitem>
|
---|
| 278 | </varlistentry>
|
---|
| 279 |
|
---|
| 280 | </variablelist>
|
---|
| 281 |
|
---|
| 282 | </sect2>
|
---|
[e40cb61] | 283 |
|
---|
[f45b1953] | 284 | </sect1>
|
---|