4957a2d0b80e62a53e14ee00f3046cd61b1e283b
[mirror/dsa-puppet.git] / modules / samhain / templates / samhainrc.erb
1 ##
2 ## THIS FILE IS UNDER PUPPET CONTROL. DON'T EDIT IT HERE.
3 ## USE: git clone git+ssh://$USER@puppet.debian.org/srv/puppet.debian.org/git/dsa-puppet.git
4 ##
5
6 #####################################################################
7 #
8 # Configuration file template for samhain.
9 #
10 #####################################################################
11
12 # -- empty lines and lines starting with '#', ';' or '//' are ignored
13 # -- boolean options can be Yes/No or True/False or 1/0 
14 # -- you can PGP clearsign this file -- samhain will check (if compiled
15 #    with support) or otherwise ignore the signature
16 # -- CHECK mail address
17 #
18 # To each log facility, you can assign a threshold severity. Only
19 # reports with at least the threshold severity will be logged
20 # to the respective facility (even further below).
21 #
22 #####################################################################
23 #
24 # SETUP for file system checking:
25
26 # (i)   There are several policies, each has its own section. Put files
27 #       into the section for the appropriate policy (see below).
28 # (ii)  Section [EventSeverity]: 
29 #       To each policy, you can assign a severity (further below).
30 # (iii) Section [Log]: 
31 #       To each log facility, you can assign a threshold severity. Only
32 #       reports with at least the threshold severity will be logged
33 #       to the respective facility (even further below).
34 #
35 #####################################################################
36
37 #####################################################################
38 #
39 # Files are defined with: file = /absolute/path
40 #
41 # Directories are defined with:                  dir = /absolute/path
42 # or with an optional recursion depth (N <= 99): dir = N/absolute/path
43 #
44 # Directory inodes are checked. If you only want to check files
45 # in a directory, but not the directory inode itself, use (e.g.):
46 #
47 # [ReadOnly]
48 # dir = /some/directory
49 # [IgnoreAll]
50 # file = /some/directory
51 #
52 # You can use shell-style globbing patterns, like: file = /path/foo*
53
54 ######################################################################
55
56 [Misc]
57 ##
58 ## Add or subtract tests from the policies
59 ## - if you want to change their definitions,
60 ##   you need to do that before using the policies
61 ##
62 # RedefReadOnly = (no default)
63 # RedefAttributes=(no default)
64 # RedefLogFiles=(no default)
65 # RedefGrowingLogFiles=(no default)
66 # RedefIgnoreAll=(no default)
67 # RedefIgnoreNone=(no default)
68 # RedefUser0=(no default)
69 # RedefUser1=(no default)
70 IgnoreMissing=/etc/lvm/archive/.*.vg
71 IgnoreMissing=/var/lib/puppet/clientbucket/.*
72
73 [Attributes]
74 ##
75 ## for these files, only changes in permissions and ownership are checked
76 ##
77 file=/etc/mtab
78 file=/etc/ssh_random_seed
79 file=/etc/asound.conf
80 file=/etc/bacula/bacula-fd.conf
81 file=/etc/localtime
82 file=/etc/ioctl.save
83 file=/etc/passwd.backup
84 file=/etc/shadow.backup
85 file=/etc/postfix/prng_exch
86 file=/etc/adjtime
87 file=/etc/lvm/.cache
88 file=/etc/lvm/cache
89 file=/etc/lvm/cache/.cache
90 file=/etc/network/run/ifstate
91 file=/var/state/samhain/samhain_file
92 file=/etc/bind/zones/db.debian.net
93 file=/etc/exim4/bsmtp
94 file=/etc/fake-hwclock.data
95 <% if classes.include?("named::geodns") -%>
96 file=/etc/bind
97 file=/etc/bind/named.conf.acl
98 file=/etc/bind/named.conf.local
99 file=/etc/bind/geodns/named.conf.geo
100 file=/etc/bind/geodns/recvconf.files
101 <% end -%>
102 <% if classes.include?("named") -%>
103 file=/etc/bind/named.conf.options
104 <% end -%>
105 file=/etc/apache2/conf.d/puppet-builddlist
106 <% if classes.include?("roles::static_mirror") -%>
107 file=/etc/apache2/sites-available/static-vhosts-simple
108 file=/etc/static-clients.conf
109 <% elsif classes.include?("roles::static_master") -%>
110 file=/etc/static-clients.conf
111 <% elsif classes.include?("roles::static_source") -%>
112 file=/etc/static-clients.conf
113 <% end -%>
114 <% if classes.include?("apache2") -%>
115 file=/etc/apache2/conf-available/puppet-ssl-key-pins.conf
116 <% end -%>
117 file=/etc/multipath/wwids
118 <%- if has_variable?("bgpd") && @bgpd -%>
119 file=/etc/quagga/bgpd.conf
120 <% end -%>
121 <%- if has_variable?("zebra") && @zebra -%>
122 file=/etc/quagga/zebra.conf
123 <% end -%>
124
125 #
126 # There are files in /etc that might change, thus changing the directory
127 # timestamps. Put it here as 'file', and in the ReadOnly section as 'dir'.
128 #
129 file=/etc
130 file=/etc/ssh
131 file=/etc/network/run
132 file=/etc/bind/zones
133 file=/etc/spamassassin/sa-update-keys
134 file=/etc/init.d/.depend.boot
135 file=/etc/init.d/.depend.start
136 file=/etc/init.d/.depend.stop
137
138 # These are the directories for the files we handle with puppet
139 <% if classes.include?("apache2") -%>
140 file=/etc/apache2/conf-available
141 files=/etc/apache2/mods-enabled
142 files=/etc/apache2/sites-available
143 <% end -%>
144 file=/etc/bacula
145 file=/etc/samhain
146 file=/etc/munin
147 file=/etc/munin/plugins
148 file=/etc/munin/plugin-conf.d
149 file=/etc/munin/munin-conf.d
150 file=/etc/exim4
151 file=/etc/exim4/ssl
152 file=/etc/apt
153 file=/etc/apt/apt.conf.d
154 file=/etc/apt/sources.list.d
155 file=/etc/apt/preferences.d
156 file=/etc/default
157 file=/etc/logrotate.d
158 file=/etc/nagios
159 file=/etc/nagios/nrpe.d
160 file=/etc/nagios/obsolete-packages-ignore.d
161 file=/etc/bind/geodns
162 <% if scope.function_has_role(['nagiosmaster']) -%>
163 file=/etc/nagios3/puppetconf.d
164 <% end -%>
165 file=/etc/puppet
166 file=/etc/cron.d
167 file=/etc/cron.weekly
168 file=/usr/lib/nagios/plugins
169 file=/usr/sbin
170 file=/etc/monit
171 file=/etc/monit/monit.d
172 file=/etc/pam.d
173 file=/etc/schroot/default
174 file=/etc/schroot/dsa
175 file=/etc/schroot/dsa/default-mirror
176 file=/etc/schroot/setup.d
177 file=/etc/sysctl.d
178 file=/etc/syslog-ng
179 file=/etc/stunnel
180 file=/etc/ferm/
181 file=/etc/ferm/conf.d
182 file=/etc/ferm/dsa.d
183 file=/etc/rc.local
184 file=/etc/unbound
185 file=/etc/dsa
186 file=/etc/rabbitmq
187 <% if scope.function_has_role(['static_mirror']) or scope.function_has_role(['static_source']) or scope.function_has_role(['static_master']) -%>
188 file=/etc/ssh/userkeys
189 file=/etc/ssh/userkeys/staticsync
190 <% end -%>
191 <% if scope.function_has_role(['ssh.upload.d.o']) -%>
192 file=/etc/ssh/userkeys/buildd-uploader
193 <% end -%>
194 <% if scope.function_has_role(['buildd_master']) -%>
195 file=/etc/ssh/userkeys/wb-buildd.more
196 <% end -%>
197 file=/etc/rsyncd
198 <%- if @hostname == "sibelius" then -%>
199 file=/etc/tsm
200 file=/etc/tsm/TSM.PWD
201 <% end -%>
202 file=/etc/ssl/private
203
204
205 [LogFiles]
206 ##
207 ## for these files, changes in signature, timestamps, and size are ignored 
208 ##
209 file=/etc/motd
210
211 # is on tmpfs, ignore.
212 #file=/var/run/utmp
213
214
215 #####################################################################
216 #
217 # This would be the proper syntax for parts that should only be
218 #    included for certain hosts.
219 # You may enclose anything in a @HOSTNAME/@end bracket, as long as the
220 #    result still has the proper syntax for the config file.
221 # You may have any number of @HOSTNAME/@end brackets.
222 # HOSTNAME should be the fully qualified 'official' name 
223 #    (e.g. 'nixon.watergate.com', not 'nixon'), no aliases. 
224 #    No IP number - except if samhain cannot determine the 
225 #    fully qualified hostname.
226 #
227 # @HOSTNAME
228 # file=/foo/bar
229 # @end
230 #
231 # These are two examples for conditional inclusion/exclusion
232 # of a machine based on the output from 'uname -srm'
233 #
234 # $Linux:2.*.7:i666
235 # file=/foo/bar3
236 # $end
237 #
238 # !$Linux:2.*.7:i686
239 # file=/foo/bar2
240 # $end
241 #
242 #####################################################################
243
244 [GrowingLogFiles]
245 ##
246 ## for these files, changes in signature, timestamps, and increase in size
247 ##                  are ignored 
248 ##
249 file=/var/log/warn
250 file=/var/log/messages
251 file=/var/log/wtmp
252 file=/var/log/faillog
253 file=/var/log/auth.log
254 file=/var/log/daemon.log
255 file=/var/log/user.log
256 file=/var/log/kern.log
257 file=/var/log/syslog
258
259
260 [IgnoreAll]
261 dir=-1/srv
262 ##
263 ## for these files, no modifications are reported
264 ##
265 ## This file might be created or removed by the system sometimes.
266 ##
267 file=/etc/resolv.conf
268 <% if scope.lookupvar('site::nodeinfo')['buildd'] -%>
269 file=/etc/dupload.conf
270 file=/etc/buildd/buildd.conf
271 file=/etc/sbuild/sbuild.conf
272 <% end -%>
273 file=/etc/resolv.conf.pcmcia.save
274 file=/etc/nologin
275 file=/etc/postfix/debian.db
276 file=/etc/postfix/debian
277 file=/etc/ssh/ssh_known_hosts
278 file=/etc/ssh/ssh-rsa-shadow
279 file=/var/lib/misc/ssh-rsa-shadow
280 file=/etc/.da-backup.trace
281 file=/etc/postfix/debianhosts
282 file=/etc/postfix/debianhosts.db
283 file=/etc/blkid.tab
284 file=/etc/blkid.tab.old
285 file=/etc/resolv.conf.dhclient-new
286
287 # We handle these files with puppet - please to not be bothering us
288 file=/etc/dsa/pubsub.conf
289 file=/etc/nsswitch.conf
290 file=/etc/timezone
291 file=/etc/motd.tail
292 file=/etc/update-motd.d/
293 file=/etc/update-motd.d/puppet-motd
294 file=/etc/ntp.conf
295 file=/etc/samhain/samhainrc
296 file=/etc/munin/munin-node.conf
297 file=/etc/munin/plugin-conf.d/munin-node
298 dir=2/etc/munin/munin-conf.d
299 file=/etc/userdir-ldap.confc
300 file=/etc/exim4/blacklist
301 file=/etc/exim4/host_blacklist
302 file=/etc/exim4/callout_users
303 file=/etc/exim4/exim4.conf
304 file=/etc/exim4/grey_users
305 file=/etc/exim4/helo-check
306 file=/etc/exim4/locals
307 file=/etc/exim4/localusers
308 file=/etc/exim4/manualroute
309 file=/etc/exim4/rbllist
310 file=/etc/exim4/rhsbllist
311 file=/etc/exim4/submission-domains
312 file=/etc/exim4/virtualdomains
313 file=/etc/exim4/email-virtualdomains
314 file=/etc/exim4/whitelist
315 file=/etc/exim4/local-settings.conf
316 file=/etc/exim4/ssl/ca.crt
317 file=/etc/exim4/ssl/ca.crl
318 file=/etc/exim4/ssl/thishost.crt
319 file=/etc/exim4/ssl/thishost.key
320 dir=3/etc/exim4/email-virtualdomains
321 file=/etc/ssh/ssh_config
322 file=/etc/ssh/sshd_config
323 file=/etc/dsa/cron.ignore.dsa-puppet-stuff
324 file=/etc/vsftpd.conf
325 file=/etc/aliases
326 file=/etc/multipath.conf
327 file=/etc/static-components.conf
328 file=/etc/rabbitmq/rabbitmq.config
329 file=/etc/rabbitmq/enabled_plugins
330 dir=/etc/bacula/storages-list.d
331 dir=/etc/bacula/storage-conf.d
332 dir=/etc/bacula/conf.d
333 <%=
334 out=""
335 if scope.lookupvar('site::nodeinfo')['heavy_exim']
336   out = '
337 file=/etc/exim4/surbl_whitelist.txt
338 file=/etc/exim4/exim_surbl.pl
339 file=/etc/exim4/ccTLD.txt
340 file=/etc/clamav-unofficial-sigs.conf
341 file=/etc/clamav-unofficial-sigs.dsa.conf
342 '
343 end
344 out
345 %>
346 file=/etc/munin/plugins/bind
347 file=/etc/munin/plugins/bind_views
348 file=/etc/munin/plugins/cpu
349 file=/etc/munin/plugins/df
350 file=/etc/munin/plugins/df_abs
351 file=/etc/munin/plugins/df_inode
352 file=/etc/munin/plugins/entropy
353 file=/etc/munin/plugins/forks
354 file=/etc/munin/plugins/interrupts
355 file=/etc/munin/plugins/iostat
356 file=/etc/munin/plugins/irqstats
357 file=/etc/munin/plugins/load
358 file=/etc/munin/plugins/memory
359 file=/etc/munin/plugins/ntp_offset
360 file=/etc/munin/plugins/ntp_states
361 file=/etc/munin/plugins/open_files
362 file=/etc/munin/plugins/open_inodes
363 file=/etc/munin/plugins/processes
364 file=/etc/munin/plugins/ps_apache2
365 file=/etc/munin/plugins/ps_exim4
366 file=/etc/munin/plugins/ps_vsftpd
367 file=/etc/munin/plugins/spamassassin
368 file=/etc/munin/plugins/swap
369 file=/etc/munin/plugins/uptime
370 file=/etc/munin/plugins/vmstat
371 file=/etc/munin/plugins/vfstpd
372 file=/etc/munin/plugins/apache_accesses
373 file=/etc/munin/plugins/apache_processes
374 file=/etc/munin/plugins/apache_volume
375 file=/etc/munin/plugins/apache_servers
376 file=/etc/munin/plugins/exim_mailqueue
377 file=/etc/munin/plugins/exim_mailstats
378 file=/etc/munin/plugins/postfix_mailqueue
379 file=/etc/munin/plugins/postfix_mailvolume
380 file=/etc/apache2/conf.d/resource-limits
381 file=/etc/apache2/mods-enabled/info.conf
382 file=/etc/apache2/mods-enabled/info.load
383 file=/etc/apache2/mods-enabled/server.conf
384 file=/etc/apache2/mods-enabled/server.load
385 file=/etc/apache2/conf.d/server-status
386 file=/etc/apache2/conf.d/local-serverinfo
387 file=/etc/apache2/sites-available/www.debian.org
388 file=/etc/apt/preferences
389 file=/etc/apt/sources.list.d/volatile.list
390 file=/etc/apt/sources.list.d/security.list
391 file=/etc/apt/sources.list.d/buildd.list
392 file=/etc/apt/sources.list.d/buildd.debian.org.list
393 file=/etc/apt/sources.list.d/buildd.debian.org-proposed.list
394 file=/etc/apt/sources.list.d/buildd.debian.org-experimental.list
395 file=/etc/apt/sources.list.d/geoip.list
396 file=/etc/apt/sources.list.d/backports.debian.org.list
397 file=/etc/apt/sources.list.d/debian.org.list
398 file=/etc/apt/sources.list.d/db.debian.org.list
399 file=/etc/apt/sources.list.d/db.debian.org.restricted.list
400 file=/etc/apt/sources.list.d/debian.list
401 file=/etc/apt/sources.list.d/backports.org.list
402 file=/etc/apt/apt.conf.d/local-compression
403 file=/etc/apt/apt.conf.d/local-recommends
404 file=/etc/apt/apt.conf.d/local-pdiffs
405 file=/etc/apt/apt.conf.d/local-ssl-ca-global
406 file=/etc/apt/preferences.d/buildd
407 file=/etc/puppet/puppet.conf
408 file=/etc/default/puppet
409 file=/etc/default/postgrey
410 file=/etc/default/syslog-ng
411 file=/etc/logrotate.d/exim4-paniclog
412 file=/etc/logrotate.d/exim4-base
413 file=/etc/logrotate.d/syslog-ng
414 file=/etc/syslog-ng/syslog-ng.conf
415 file=/usr/sbin/dsa-update-apt-status
416 file=/usr/sbin/dsa-update-samhain-status
417 file=/etc/nagios/nrpe.d/nrpe_dsa.cfg
418 file=/etc/nagios/nrpe.d/debianorg.cfg
419 file=/etc/nagios/obsolete-packages-ignore
420 file=/etc/nagios/obsolete-packages-ignore.d/hostspecific
421 file=/etc/nagios/check-libs.conf
422 file=/usr/lib/nagios/plugins/dsa-check-packages
423 file=/usr/lib/nagios/plugins/dsa-check-soas
424 file=/usr/lib/nagios/plugins/dsa-check-mirrorsync
425 file=/usr/lib/nagios/plugins/dsa-check-samhain
426 file=/usr/lib/nagios/plugins/dsa-check-statusfile
427 file=/usr/lib/nagios/plugins/dsa-check-dabackup-server
428 file=/usr/lib/nagios/plugins/dsa-check-config
429 file=/usr/lib/nagios/plugins/dsa-check-hpacucli
430 file=/usr/lib/nagios/plugins/dsa-check-raid-mpt
431 file=/usr/lib/nagios/plugins/dsa-check-puppet
432 file=/usr/lib/nagios/plugins/dsa-check-running-kernel
433 file=/usr/lib/nagios/plugins/dsa-check-raid-3ware
434 file=/usr/lib/nagios/plugins/dsa-check-dabackup
435 file=/usr/lib/nagios/plugins/dsa-check-raid-dac960
436 file=/usr/lib/nagios/plugins/dsa-check-udldap-freshness
437 file=/usr/lib/nagios/plugins/dsa-check-raid-areca
438 file=/usr/lib/nagios/plugins/dsa-check-raid-sw
439 file=/usr/lib/nagios/plugins/dsa-update-samhain-status
440 file=/etc/sudoers
441 file=/etc/stunnel/puppet-ekeyd-peer.pem
442 file=/etc/stunnel/puppet-ekeyd.conf
443 file=/etc/pam.d/sudo
444 file=/etc/monit/monitrc
445 file=/etc/monit/monit.d/01puppet
446 file=/etc/monit/monit.d/00debian.org
447 file=/etc/cron.d/dsa-puppet-stuff
448 file=/etc/cron.weekly/stunnel-ekey-restart
449 file=/etc/default/schroot
450 file=/etc/schroot/default/nssdatabases
451 file=/etc/schroot/setup.d/99builddsourceslist
452 file=/etc/schroot/setup.d/99porterbox-extra-sources
453 file=/etc/schroot/setup.d/99porterbox-extra-apt-options
454 file=/etc/openvswitch/conf.db
455
456 <% if scope.function_has_role(['nagiosmaster']) -%>
457 file=/etc/nagios3/puppetconf.d/auto-hostgroups.cfg
458 file=/etc/nagios3/puppetconf.d/auto-hosts.cfg
459 file=/etc/nagios3/puppetconf.d/auto-services.cfg
460 file=/etc/nagios3/puppetconf.d/auto-dependencies.cfg
461 file=/etc/nagios3/puppetconf.d/auto-hostextinfo.cfg
462 file=/etc/nagios3/puppetconf.d/auto-serviceextinfo.cfg
463 file=/etc/nagios3/puppetconf.d/auto-servicegroups.cfg
464 file=/etc/nagios3/puppetconf.d/contacts.cfg
465 <% end -%>
466 <% if scope.function_has_role(['muninmaster']) -%>
467 file=/etc/munin/munin.conf
468 <% end -%>
469 <% if scope.function_has_role(['puppetmaster']) -%>
470 dir=8/etc/puppet
471 <% end -%>  
472 <% if classes.include?('named::geodns') -%>
473 dir=1/etc/bind/geodns
474 <% end -%>
475 <% if classes.include?('named::authoritative') -%>
476 dir=1/etc/bind
477 file=/etc/bind/named.conf.debian-zones
478 <% end -%>
479 dir=3/etc/lvm/archive
480 dir=3/etc/lvm/backup
481 dir=1/etc/ferm/dsa.d
482 dir=1/etc/ferm/conf.d
483 dir=3/etc/facter
484 file=/etc/ferm/conf.d/me.conf
485 file=/etc/ferm/conf.d/defs.conf
486 file=/etc/ferm/ferm.conf
487 file=/etc/ssl/README
488 dir=2/etc/ssl/debian
489 dir=1/etc/ssl/certs
490 dir=1/etc/ssl/ca-debian
491 dir=1/etc/ssl/ca-global
492 file=/etc/ca-certificates.conf
493 file=/etc/ca-certificates-debian.conf
494 file=/etc/ca-certificates-global.conf
495 file=/etc/ssl/private/ssl-cert-snakeoil.key
496 file=/etc/unbound/unbound.conf
497 <% if scope.lookupvar('::fqdn') == "draghi.debian.org" -%>
498 file=/etc/openvpn/deb-mgmt-clients.pool
499 <% end -%>
500 file=/etc/rsyncd/debian.secrets
501
502
503 <% if scope.function_has_role(['puppetmaster']) %>
504
505 # Damn you rails apps and your shoddy packaging
506 file=/usr/share/puppet-dashboard/public/stylesheets
507 file=/usr/share/puppet-dashboard/public/javascripts
508 file=/usr/share/puppet-dashboard/public/stylesheets/all.css
509 file=/usr/share/puppet-dashboard/public/javascripts/all.js
510 dir=1/usr/share/puppet-dashboard/tmp/pids
511 <% end -%>
512
513 <% if classes.include?("porterbox") %>
514 file=/etc/cron.weekly/puppet-mail-big-homedirs
515 <% end -%>
516 file=/etc/ssl/private/*.key-certchain
517 dir=10/var/lib/puppet/clientbucket
518
519 [IgnoreNone]
520 ##
521 ## for these files, all modifications (even access time) are reported
522 ##    - you may create some interesting-looking file (like /etc/safe_passwd),
523 ##      just to watch whether someone will access it ...
524 ##
525
526 [Prelink]
527 ##
528 ## Use for prelinked files or directories holding them
529 ##
530
531
532 [ReadOnly]
533 ##
534 ## for these files, only access time is ignored
535 ##
536 dir=/usr/bin
537 dir=/bin
538 dir=/boot
539 #
540 # SuSE (old) has the boot init scripts in /sbin/init.d/*, 
541 # so we go 3 levels deep
542 #
543 dir=3/sbin
544 dir=/usr/sbin
545 dir=/lib
546 dir=3/usr/lib
547 dir=3/usr/share
548 #
549 # RedHat and Debian have the bootinit scripts in /etc/init.d/* or /etc/rc.d/*, 
550 #        so we go 3 levels deep there too
551 #
552 dir=3/etc
553
554 # Various directories / files that may include / be SUID/SGID binaries
555 #
556 #
557 file=/usr/lib/pt_chown
558 # X11, in Debian X7 this is now a symlink
559 #dir=/usr/X11R6/bin
560 #dir=/usr/X11R6/lib/X11/xmcd/bin
561 # Apache:
562 #file=/usr/lib/apache/suexec
563 #file=/usr/lib/apache/suexec.disabled
564 # Extra directories:
565 #dir=/opt/gnome/bin
566 #dir=/opt/kde/bin
567
568 [User0]
569 [User1]
570 ## User0 and User1 are sections for files/dirs with user-definable checking
571 ## (see the manual) 
572
573
574 [EventSeverity]
575 ##
576 ## Here you can assign severities to policy violations.
577 ## If this severity exceeds the treshold of a log facility (see below),
578 ## a policy violation will be logged to that facility.
579 ##
580 ## Severity for verification failures.
581 ##
582 # SeverityReadOnly=crit
583 # SeverityLogFiles=crit
584 # SeverityGrowingLogs=crit
585 # SeverityIgnoreNone=crit
586 # SeverityAttributes=crit
587 # SeverityUser0=crit
588 # SeverityUser1=crit
589
590 # Default behaviour
591 SeverityReadOnly=crit
592 SeverityLogFiles=crit
593 SeverityGrowingLogs=warn
594 SeverityIgnoreNone=crit
595 SeverityAttributes=crit
596
597
598 ##
599 ## We have a file in IgnoreAll that might or might not be present.
600 ## Setting the severity to 'info' prevents messages about deleted/new file.
601 ##
602 # SeverityIgnoreAll=crit
603 SeverityIgnoreAll=info
604
605 ## Files : file access problems
606 # SeverityFiles=crit
607
608 ## Dirs  : directory access problems
609 # SeverityDirs=crit
610
611 ## Names : suspect (non-printable) characters in a pathname
612 # SeverityNames=crit
613
614 # Default behaviour
615 SeverityFiles=crit
616 SeverityDirs=crit
617 SeverityNames=warn
618
619
620 [Log]
621 ##
622 ## Switch on/OFF log facilities and set their threshold severity
623 ##
624 ## Values: debug, info, notice, warn, mark, err, crit, alert, none.
625 ## 'mark' is used for timestamps.
626 ##
627 ##
628 ## Use 'none' to SWITCH OFF a log facility
629 ## 
630 ## By default, everything equal to and above the threshold is logged.
631 ## The specifiers '*', '!', and '=' are interpreted as  
632 ## 'all', 'all but', and 'only', respectively (like syslogd(8) does, 
633 ## at least on Linux). Examples:
634 ## MailSeverity=*
635 ## MailSeverity=!warn
636 ## MailSeverity==crit
637
638 ## E-mail
639 ##
640 # MailSeverity=none
641
642 ## Console
643 ##
644 # PrintSeverity=info
645
646 ## Logfile
647 ##
648 # LogSeverity=mark
649
650 ## Syslog
651 ##
652 # SyslogSeverity=none
653
654 ## Remote server (yule)
655 ##
656 # ExportSeverity=none
657
658 ## External script or program
659 ##
660 # ExternalSeverity = none
661
662 ## Logging to a database
663 ##
664 # DatabaseSeverity = none
665
666 # Default behaviour
667 MailSeverity=crit
668 PrintSeverity=none
669 LogSeverity=info
670 SyslogSeverity=alert
671 #ExportSeverity=none
672
673
674
675
676
677 #####################################################
678 #
679 # Optional modules
680 #
681 #####################################################
682
683 [SuidCheck]
684 ##
685 ## --- Check the filesystem for SUID/SGID binaries
686 ## 
687
688 ## Switch off
689 #
690 SuidCheckActive = 0
691
692 ## Interval for check (seconds)
693 #
694 # SuidCheckInterval = 7200
695
696 ## Alternative: crontab-like schedule
697 #
698 # SuidCheckSchedule = NULL
699  
700 ## Directory to exclude 
701 #
702 # SuidCheckExclude = NULL
703
704 ## Limit on files per second (0 == no limit)
705 #
706 # SuidCheckFps = 0
707
708 ## Alternative: yield after every file
709 #
710 # SuidCheckYield = no
711
712 ## Severity of a detection
713 #
714 # SeveritySuidCheck = crit
715
716 ## Quarantine SUID/SGID files if found
717 #
718 # SuidCheckQuarantineFiles = yes
719
720 ## Method for Quarantining files:
721 #  0 - Delete or truncate the file.
722 #  1 - Remove SUID/SGID permissions from file.
723 #  2 - Move SUID/SGID file to quarantine dir.
724 #
725 # SuidCheckQuarantineMethod = 0
726
727 ## For method 1 and 3, really delete instead of truncating
728
729 # SuidCheckQuarantineDelete = yes
730
731 # [Kernel]
732 ##
733 ## --- Check for loadable kernel module rootkits (Linux/FreeBSD only) 
734 ##
735
736 ## Switch on/off
737 #
738 #KernelCheckActive = True
739
740 ## Check interval (seconds); btw., the check is VERY fast
741 #
742 # KernelCheckInterval = 300
743
744 ## Severity
745 #
746 # SeverityKernel = crit
747
748
749 # [Utmp]
750 ##
751 ## --- Logging of login/logout events
752 ##
753
754 ## Switch on/off
755 #
756 # LoginCheckActive = True
757
758 ## Severity for logins, multiple logins, logouts
759
760 # SeverityLogin=info
761 # SeverityLoginMulti=warn
762 # SeverityLogout=info
763
764 ## Interval for login/logout checks
765 #
766 # LoginCheckInterval = 300
767
768
769 # [Database]
770 ##
771 ## --- Logging to a relational database
772 ##
773
774 ## Database name
775 #
776 # SetDBName = samhain
777
778 ## Database table
779 #
780 # SetDBTable = log
781
782 ## Database user
783 #
784 # SetDBUser = samhain
785
786 ## Database password
787 #
788 # SetDBPassword = (default: none)
789
790 ## Database host
791 #
792 # SetDBHost = localhost
793
794 ## Log the server timestamp for received messages
795 #
796 # SetDBServerTstamp = True
797
798 ## Use a persistent connection
799 #
800 # UsePersistent = True
801
802 # [External]
803 ##
804 ## Interface to call external scripts/programs for logging
805 ##
806
807 ## The absolute path to the command
808 ## - Each invocation of this directive will end the definition of the
809 ##   preceding command, and start the definition of 
810 ##   an additional, new command
811 #
812 # OpenCommand = (no default)
813
814 ## Type (log or rv)
815 ## - log for log messages, srv for messages received by the server
816 #
817 # SetType = log
818
819 ## The command (full command line) to execute
820 #
821 # SetCommandLine = (no default)
822
823 ## The environment (KEY=value; repeat for more)
824 #
825 # SetEnviron = TZ=(your timezone)
826
827 ## The TIGER192 checksum (optional)
828 #
829 # SetChecksum = (no default)
830
831 ## User who runs the command
832 #
833 # SetCredentials = (default: samhain process uid)
834
835 ## Words not allowed in message
836 #
837 # SetFilterNot = (none)
838
839 ## Words required (ALL of them)
840 #
841 # SetFilterAnd = (none)
842
843 ## Words required (at least one)
844 #
845 # SetFilterOr = (none)
846
847 ## Deadtime between consecutive calls
848 #
849 # SetDeadtime = 0
850
851 ## Add default environment (HOME, PATH, SHELL)
852 #
853 # SetDefault = no
854
855 <% if scope.call_function('versioncmp', [@lsbmajdistrelease, '9']) >= 0 -%>
856 [PortCheck]
857 PortCheckActive=0
858 <% end -%>
859
860
861 #####################################################
862 #
863 # Miscellaneous configuration options
864 #
865 #####################################################
866
867 [Misc]
868
869 ## whether to become a daemon process
870 ## (this is not honoured on database initialisation)
871 #
872 # Daemon = no
873 Daemon = yes
874
875 ## whether to test signature of files (init/check/none)
876 ## - if 'none', then we have to decide this on the command line -
877 #
878 # ChecksumTest = none
879 ChecksumTest=check
880
881 ## whether to drop linux capabilities that are not required
882 ## - will make a root process a 'mere mortal' in many respects
883 #
884 # UseCaps = yes
885
886 ## Set nice level (-19 to 19, see 'man nice'),
887 ## and I/O limit (kilobytes per second; 0 == off)
888 ## to reduce load on host.
889 #
890 # SetNiceLevel = 0
891 # SetIOLimit = 0
892
893 ## The version string to embed in file signature databases
894 #
895 # VersionString = NULL
896
897 ## Interval between time stamp messages
898 #
899 # SetLoopTime = 60
900 SetLoopTime = 600
901
902 ## Interval between file checks 
903 #
904 # SetFileCheckTime = 600
905 SetFileCheckTime = 7200
906
907 ## Alternative: crontab-like schedule
908 #
909 # FileCheckScheduleOne = NULL
910
911 ## Alternative: crontab-like schedule(2)
912 #
913 # FileCheckScheduleTwo = NULL
914
915 ## Report only once on modified fles 
916 ## Setting this to 'FALSE' will generate a report for any policy 
917 ## violation (old and new ones) each time the daemon checks the file system.
918 #
919 # ReportOnlyOnce = True
920
921 ## Report in full detail
922 #
923 # ReportFullDetail = False
924
925 ## Report file timestamps in local time rather than GMT
926 #
927 # UseLocalTime = No
928
929 ## The console device (can also be a file or named pipe)
930 ## - There are two console devices. Accordingly, you can use
931 ##   this directive a second time to set the second console device.
932 ##   If you have not defined the second device at compile time,
933 ##   and you don't want to use it, then:
934 ##   setting it to /dev/null is less effective than just leaving
935 ##   it alone (setting to /dev/null will waste time by opening
936 ##   /dev/null and writing to it)
937 #
938 # SetConsole = /dev/console
939
940 ## Activate the SysV IPC message queue
941 #
942 # MessageQueueActive = False
943
944
945 ## If false, skip reverse lookup when connecting to a host known 
946 ## by name rather than IP address (i.e. trust the DNS)
947 #
948 # SetReverseLookup = True
949
950 ## --- E-Mail ---
951
952 # Only highest-level (alert) reports will be mailed immediately,
953 # others will be queued. Here you can define, when the queue will
954 # be flushed (Note: the queue is automatically flushed after
955 # completing a file check).
956 #
957 SetMailTime = 86400
958
959 ## Maximum number of mails to queue
960 #
961 SetMailNum = 10
962
963 ## Recipient (max. 8)
964 #
965 SetMailAddress=samhain-reports@<%= @fqdn -%>
966
967 SetMailRelay = localhost
968
969 ## Custom subject format
970 #
971 MailSubject = [Samhain at %H] %T: %S
972
973 ## --- end E-Mail ---
974
975 ## Path to the prelink executable
976 #
977 # SetPrelinkPath = /usr/sbin/prelink
978
979 ## TIGER192 checksum of the prelink executable
980 #
981 # SetPrelinkChecksum = (no default)
982
983
984 ## Path to the executable. If set, will be checksummed after startup
985 ## and before exit.
986 #
987 # SamhainPath = (no default)
988
989
990 ## The IP address of the log server
991 #
992 # SetLogServer = (default: compiled-in)
993
994 ## The IP address of the time server
995 #
996 # SetTimeServer = (default: compiled-in)
997
998 ## Trusted Users (comma delimited list of user names) 
999 #
1000 # TrustedUser = (no default; this adds to the compiled-in list)
1001
1002 ## Path to the file signature database
1003 #
1004 # SetDatabasePath = (default: compiled-in)
1005
1006 ## Path to the log file
1007 #
1008 # SetLogfilePath = (default: compiled-in)
1009
1010 ## Path to the PID file
1011 #
1012 # SetLockPath = (default: compiled-in)
1013
1014
1015 ## The digest/checksum/hash algorithm
1016 #
1017 # DigestAlgo = TIGER192
1018
1019
1020 ## Custom format for message header. 
1021 ## CAREFUL if you use XML logfile format.
1022 ##
1023 ## %S severity
1024 ## %T timestamp
1025 ## %C class
1026 ##
1027 ## %F source file
1028 ## %L source line
1029 #
1030 # MessageHeader="%S %T "
1031
1032
1033 ## Don't log path to config/database file on startup
1034 #
1035 # HideSetup = False
1036
1037 ## The syslog facility, if you log to syslog
1038 #
1039 # SyslogFacility = LOG_AUTHPRIV
1040 SyslogFacility=LOG_LOCAL2
1041
1042 ## The message authentication method
1043 ## - If you change this, you *must* change it
1044 ##   on client *and* server
1045 #
1046 # MACType = HMAC-TIGER
1047
1048
1049 ## everything below is ignored
1050 [EOF]
1051
1052 #####################################################################
1053 # This would be the proper syntax for parts that should only be
1054 #    included for certain hosts.
1055 # You may enclose anything in a @HOSTNAME/@end bracket, as long as the
1056 #    result still has the proper syntax for the config file.
1057 # You may have any number of @HOSTNAME/@end brackets.
1058 # HOSTNAME should be the fully qualified 'official' name 
1059 #    (e.g. 'nixon.watergate.com', not 'nixon'), no aliases. 
1060 #    No IP number - except if samhain cannot determine the 
1061 #    fully qualified hostname.
1062 #
1063 # @HOSTNAME
1064 # file=/foo/bar
1065 # @end
1066 #
1067 # These are two examples for conditional inclusion/exclusion
1068 # of a machine based on the output from 'uname -srm'
1069 # $Linux:2.*.7:i666
1070 # file=/foo/bar3
1071 # $end
1072 #
1073 # !$Linux:2.*.7:i686
1074 # file=/foo/bar2
1075 # $end
1076 #
1077 #####################################################################