This expansion contains the following key terms:
SSH-based
: The file integrity scan is (usually) performed over an
ssh-connection. Usually the computer being scanned (called the client) and
the computer initiating the scan (called the monitor
) are different
computers.
Trust Enforcement
: following the scan, `trust' is enforced in the
client, due to the integrity of its files.
Locally Trusted Host
: the client apparently trusts the monitor
to use an ssh-connection to perform commands on it. The client therefore
locally trusts the monitor. Hence, locally trusted host.
stealth is based on an idea by Hans Gankema and Kees Visser, both at the Center for Information Technology of the University of Groningen.
stealth's main task is to perform file integrity tests. However, the testing will leave virtually no sediments on the tested computer. Therefore, stealth has stealthy characteristics. I consider this an important security improving feature of stealth.
The monitor itself only needs two kinds of outgoing services: ssh(1) to reach its clients, and some mail transport agent (e.g., sendmail(1)) to forward its outgoing mail to some mail-hub.
Here is what happens when stealth is run:
--daemon <uds>
is specified, stealth
runs as a daemon process, using the Unix Domain Socket (<uds>
) for
communication with stealth processes running in IPC mode.
If access to the Unix Domain Socket defined by Stealth running in daemon mode should be restricted, it can be defined in a directory with is only accessible to the user running Stealth (this will often be the root-user).
When running in daemon mode, --repeat <seconds>
may be specified to rerun
the integrity scan every <seconds>
seconds. If an integrity scan is being
performed when, according to the repeat interval the next integrity scan is
due, then the current scan is first completed. Once completed, the next
integrity scan will be performed after seconds
seconds.
-printf
method
to produce file-integrity related statistics. Most of these programs write
file names at the end of generated lines. This characteristic is used by one
of stealth's internal routines to detect changes in the generated output. Such
changes could indicate some harmful intent, like an installed root-kit.
--suspend
and --resume
commands (see below at the section
5.7).
Instead of running in daemon mode, stealth may also run in `foreground' mode.
In foreground mode the option --daemon
is not specified. When running in
foreground mode stealth either performs one integrity scan (and terminates) or, if
the --repeat
option has been specified, it repeatedly performs integrity
scans, at intervals determined by the --repeat
and --random-interval
options. When --repeat
is specified with stealth running in foreground mode a
prompt is shown (i.e., `?
') with stealth terminating after pressing the
Enter
-key.
Alternatively, stealth may run in `inter process communication' mode (IPC
mode). IPC mode is characterized by using one of the command-line options
--reload, --rerun, --suspend, --resume
or --terminate
. In IPC-mode stealth
communicates with an existing stealth daemon, using the Unix Domain Socket defined
by the stealth daemon. These options require but one argument: the location of the
Unix Domain Socket defined by a running stealth daemon.
--reload <uds>
command-line option, the
stealth daemon that created the Unix Domain Socket reloads its policy file
(and skip-file), immediately followed by another integrity scan;
--rerun <uds>
command-line option, the
stealth daemon that created the Unix Domain Socket performs another integrity
scan;
--terminate <usd>
command-line option, the
stealth daemon that created the Unix Domain Socket terminates.
The options --suspend
and --resume
(see section 5.7) were
implemented to allow safe rotations of stealth's log-files.
USE
BASE
.
documentation/images
.
copytruncate
' and 'sharedscripts
' (see section 5.7
for an example)
sha1sum
when checking hash
values. Stronger hash functions (like sha256sum
) might be
preferred in practice. When updating existing policy files to use
sha256sum
rather than sha1sum
realize that sha256sum's
hash values are longer than sha1sum's
hash values, and that
therefore log files obtained when sha1sum
was used are
incompatible with log files obtained when sha256sum
was used. In
practice this means that new log files need to be generated,
disregarding any previously geneerated log files.