eb9eef70da5233d56abf6e723f537bd761106f50
[mirror/dsa-puppet.git] / modules / samhain / files / common / samhainrc
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
71 [Attributes]
72 ##
73 ## for these files, only changes in permissions and ownership are checked
74 ##
75 file=/etc/mtab
76 file=/etc/ssh_random_seed
77 file=/etc/asound.conf
78 file=/etc/resolv.conf
79 file=/etc/localtime
80 file=/etc/ioctl.save
81 file=/etc/passwd.backup
82 file=/etc/shadow.backup
83 file=/etc/postfix/prng_exch
84 file=/etc/adjtime
85 file=/etc/lvm/.cache
86 file=/etc/lvm/cache
87 file=/etc/lvm/cache/.cache
88 file=/etc/network/run/ifstate
89 file=/var/state/samhain/samhain_file
90 file=/etc/bind/db.debian.net
91 file=/etc/exim4/bsmtp
92
93
94
95 #
96 # There are files in /etc that might change, thus changing the directory
97 # timestamps. Put it here as 'file', and in the ReadOnly section as 'dir'.
98 #
99 file=/etc
100 file=/etc/ssh
101 file=/etc/network/run
102 file=/etc/bind
103
104 # These are the directories for the files we handle with puppet
105 file=/etc/samhain
106 file=/etc/munin
107 file=/etc/exim4
108 file=/etc/exim4/ssl
109 file=/etc/apt
110 file=/etc/apt/apt.conf.d
111 file=/etc/apt/sources.list.d
112 file=/etc/puppet
113 file=/etc/default
114 file=/etc/logrotate.d
115 file=/etc/nagios
116 file=/etc/nagios/nrpe.d
117 file=/etc/cron.d
118 file=/usr/lib/nagios/plugins
119 file=/usr/sbin
120
121 [LogFiles]
122 ##
123 ## for these files, changes in signature, timestamps, and size are ignored 
124 ##
125 file=/var/run/utmp
126 file=/etc/motd
127
128
129
130 #####################################################################
131 #
132 # This would be the proper syntax for parts that should only be
133 #    included for certain hosts.
134 # You may enclose anything in a @HOSTNAME/@end bracket, as long as the
135 #    result still has the proper syntax for the config file.
136 # You may have any number of @HOSTNAME/@end brackets.
137 # HOSTNAME should be the fully qualified 'official' name 
138 #    (e.g. 'nixon.watergate.com', not 'nixon'), no aliases. 
139 #    No IP number - except if samhain cannot determine the 
140 #    fully qualified hostname.
141 #
142 # @HOSTNAME
143 # file=/foo/bar
144 # @end
145 #
146 # These are two examples for conditional inclusion/exclusion
147 # of a machine based on the output from 'uname -srm'
148 #
149 # $Linux:2.*.7:i666
150 # file=/foo/bar3
151 # $end
152 #
153 # !$Linux:2.*.7:i686
154 # file=/foo/bar2
155 # $end
156 #
157 #####################################################################
158
159 [GrowingLogFiles]
160 ##
161 ## for these files, changes in signature, timestamps, and increase in size
162 ##                  are ignored 
163 ##
164 file=/var/log/warn
165 file=/var/log/messages
166 file=/var/log/wtmp
167 file=/var/log/faillog
168 file=/var/log/auth.log
169 file=/var/log/daemon.log
170 file=/var/log/user.log
171 file=/var/log/kern.log
172 file=/var/log/syslog
173
174
175 [IgnoreAll]
176 ##
177 ## for these files, no modifications are reported
178 ##
179 ## This file might be created or removed by the system sometimes.
180 ##
181 file=/etc/resolv.conf.pcmcia.save
182 file=/etc/nologin
183 file=/etc/postfix/debian.db
184 file=/etc/postfix/debian
185 file=/etc/ssh/ssh_known_hosts
186 file=/etc/ssh/ssh-rsa-shadow
187 file=/var/lib/misc/ssh-rsa-shadow
188 file=/etc/.da-backup.trace
189 file=/etc/postfix/debianhosts
190 file=/etc/postfix/debianhosts.db
191
192 # We handle these files with puppet - please to not be bothering us
193 file=/etc/samhain/samhainrc
194 file=/etc/munin/munin-node.conf
195 file=/etc/exim4/blacklist
196 file=/etc/exim4/callout_users
197 file=/etc/exim4/exim4.conf
198 file=/etc/exim4/grey_users
199 file=/etc/exim4/helo-check
200 file=/etc/exim4/locals
201 file=/etc/exim4/localusers
202 file=/etc/exim4/rbllist
203 file=/etc/exim4/rcpthosts
204 file=/etc/exim4/rhsbllist
205 file=/etc/exim4/virtualdomains
206 file=/etc/exim4/whitelist
207 file=/etc/exim4/local-auto.conf
208 file=/etc/exim4/ssl/ca.crt
209 file=/etc/exim4/ssl/ca.crl
210 file=/etc/exim4/ssl/thishost.crt
211 file=/etc/exim4/ssl/thishost.key
212 file=/etc/apt/preferences
213 file=/etc/apt/sources.list.d/volatile.list
214 file=/etc/apt/sources.list.d/security.list
215 file=/etc/apt/sources.list.d/debian.org.list
216 file=/etc/apt/sources.list.d/debian.restricted.list
217 file=/etc/apt/sources.list.d/debian.list
218 file=/etc/apt/sources.list.d/backports.org.list
219 file=/etc/apt/apt.conf.d/local-recommends
220 file=/etc/apt/apt.conf.d/local-pdiffs
221 file=/etc/puppet/puppet.conf
222 file=/etc/default/puppet
223 file=/etc/logrotate.d/exim4-paniclog
224 file=/etc/logrotate.d/exim4-base
225 file=/usr/sbin/dsa-update-apt-status
226 file=/usr/sbin/dsa-update-samhain-status
227 file=/etc/nagios/nrpe.d/nrpe_dsa.cfg
228 file=/etc/nagios/nrpe.d/debianorg.cfg
229 file=/etc/nagios/obsolete-packages-ignore
230 file=/usr/lib/nagios/plugins/dsa-check-packages
231 file=/usr/lib/nagios/plugins/dsa-check-soas
232 file=/usr/lib/nagios/plugins/dsa-check-mirrorsync
233 file=/usr/lib/nagios/plugins/dsa-check-samhain
234 file=/usr/lib/nagios/plugins/dsa-check-statusfile
235 file=/usr/lib/nagios/plugins/dsa-check-dabackup-server
236 file=/usr/lib/nagios/plugins/dsa-check-config
237 file=/usr/lib/nagios/plugins/dsa-check-hpacucli
238 file=/usr/lib/nagios/plugins/dsa-check-raid-mpt
239 file=/usr/lib/nagios/plugins/dsa-check-puppet
240 file=/usr/lib/nagios/plugins/dsa-check-running-kernel
241 file=/usr/lib/nagios/plugins/dsa-check-raid-3ware
242 file=/usr/lib/nagios/plugins/dsa-check-dabackup
243 file=/usr/lib/nagios/plugins/dsa-check-raid-dac960
244 file=/usr/lib/nagios/plugins/dsa-check-udldap-freshness
245 file=/usr/lib/nagios/plugins/dsa-check-raid-areca
246 file=/usr/lib/nagios/plugins/dsa-check-raid-sw
247 file=/usr/lib/nagios/plugins/dsa-update-samhain-status
248
249 [IgnoreNone]
250 ##
251 ## for these files, all modifications (even access time) are reported
252 ##    - you may create some interesting-looking file (like /etc/safe_passwd),
253 ##      just to watch whether someone will access it ...
254 ##
255
256 [Prelink]
257 ##
258 ## Use for prelinked files or directories holding them
259 ##
260
261
262 [ReadOnly]
263 ##
264 ## for these files, only access time is ignored
265 ##
266 dir=/usr/bin
267 dir=/bin
268 dir=/boot
269 #
270 # SuSE (old) has the boot init scripts in /sbin/init.d/*, 
271 # so we go 3 levels deep
272 #
273 dir=3/sbin
274 dir=/usr/sbin
275 dir=/lib
276 dir=3/usr/lib
277 #
278 # RedHat and Debian have the bootinit scripts in /etc/init.d/* or /etc/rc.d/*, 
279 #        so we go 3 levels deep there too
280 #
281 dir=3/etc
282
283 # Various directories / files that may include / be SUID/SGID binaries
284 #
285 #
286 file=/usr/lib/pt_chown
287 # X11, in Debian X7 this is now a symlink
288 #dir=/usr/X11R6/bin
289 #dir=/usr/X11R6/lib/X11/xmcd/bin
290 # Apache:
291 #file=/usr/lib/apache/suexec
292 #file=/usr/lib/apache/suexec.disabled
293 # Extra directories:
294 #dir=/opt/gnome/bin
295 #dir=/opt/kde/bin
296
297 [User0]
298 [User1]
299 ## User0 and User1 are sections for files/dirs with user-definable checking
300 ## (see the manual) 
301
302
303 [EventSeverity]
304 ##
305 ## Here you can assign severities to policy violations.
306 ## If this severity exceeds the treshold of a log facility (see below),
307 ## a policy violation will be logged to that facility.
308 ##
309 ## Severity for verification failures.
310 ##
311 # SeverityReadOnly=crit
312 # SeverityLogFiles=crit
313 # SeverityGrowingLogs=crit
314 # SeverityIgnoreNone=crit
315 # SeverityAttributes=crit
316 # SeverityUser0=crit
317 # SeverityUser1=crit
318
319 # Default behaviour
320 SeverityReadOnly=crit
321 SeverityLogFiles=crit
322 SeverityGrowingLogs=warn
323 SeverityIgnoreNone=crit
324 SeverityAttributes=crit
325
326
327 ##
328 ## We have a file in IgnoreAll that might or might not be present.
329 ## Setting the severity to 'info' prevents messages about deleted/new file.
330 ##
331 # SeverityIgnoreAll=crit
332 SeverityIgnoreAll=info
333
334 ## Files : file access problems
335 # SeverityFiles=crit
336
337 ## Dirs  : directory access problems
338 # SeverityDirs=crit
339
340 ## Names : suspect (non-printable) characters in a pathname
341 # SeverityNames=crit
342
343 # Default behaviour
344 SeverityFiles=crit
345 SeverityDirs=crit
346 SeverityNames=warn
347
348
349 [Log]
350 ##
351 ## Switch on/OFF log facilities and set their threshold severity
352 ##
353 ## Values: debug, info, notice, warn, mark, err, crit, alert, none.
354 ## 'mark' is used for timestamps.
355 ##
356 ##
357 ## Use 'none' to SWITCH OFF a log facility
358 ## 
359 ## By default, everything equal to and above the threshold is logged.
360 ## The specifiers '*', '!', and '=' are interpreted as  
361 ## 'all', 'all but', and 'only', respectively (like syslogd(8) does, 
362 ## at least on Linux). Examples:
363 ## MailSeverity=*
364 ## MailSeverity=!warn
365 ## MailSeverity==crit
366
367 ## E-mail
368 ##
369 # MailSeverity=none
370
371 ## Console
372 ##
373 # PrintSeverity=info
374
375 ## Logfile
376 ##
377 # LogSeverity=mark
378
379 ## Syslog
380 ##
381 # SyslogSeverity=none
382
383 ## Remote server (yule)
384 ##
385 # ExportSeverity=none
386
387 ## External script or program
388 ##
389 # ExternalSeverity = none
390
391 ## Logging to a database
392 ##
393 # DatabaseSeverity = none
394
395 # Default behaviour
396 MailSeverity=crit
397 PrintSeverity=none
398 LogSeverity=info
399 SyslogSeverity=alert
400 ExportSeverity=none
401
402
403
404
405
406 #####################################################
407 #
408 # Optional modules
409 #
410 #####################################################
411
412 # [SuidCheck]
413 ##
414 ## --- Check the filesystem for SUID/SGID binaries
415 ## 
416
417 ## Switch on
418 #
419 # SuidCheckActive = yes
420
421 ## Interval for check (seconds)
422 #
423 # SuidCheckInterval = 7200
424
425 ## Alternative: crontab-like schedule
426 #
427 # SuidCheckSchedule = NULL
428  
429 ## Directory to exclude 
430 #
431 # SuidCheckExclude = NULL
432
433 ## Limit on files per second (0 == no limit)
434 #
435 # SuidCheckFps = 0
436
437 ## Alternative: yield after every file
438 #
439 # SuidCheckYield = no
440
441 ## Severity of a detection
442 #
443 # SeveritySuidCheck = crit
444
445 ## Quarantine SUID/SGID files if found
446 #
447 # SuidCheckQuarantineFiles = yes
448
449 ## Method for Quarantining files:
450 #  0 - Delete or truncate the file.
451 #  1 - Remove SUID/SGID permissions from file.
452 #  2 - Move SUID/SGID file to quarantine dir.
453 #
454 # SuidCheckQuarantineMethod = 0
455
456 ## For method 1 and 3, really delete instead of truncating
457
458 # SuidCheckQuarantineDelete = yes
459
460 # [Kernel]
461 ##
462 ## --- Check for loadable kernel module rootkits (Linux/FreeBSD only) 
463 ##
464
465 ## Switch on/off
466 #
467 KernelCheckActive = True
468
469 ## Check interval (seconds); btw., the check is VERY fast
470 #
471 # KernelCheckInterval = 300
472
473 ## Severity
474 #
475 # SeverityKernel = crit
476
477
478 # [Utmp]
479 ##
480 ## --- Logging of login/logout events
481 ##
482
483 ## Switch on/off
484 #
485 LoginCheckActive = True
486
487 ## Severity for logins, multiple logins, logouts
488
489 # SeverityLogin=info
490 # SeverityLoginMulti=warn
491 # SeverityLogout=info
492
493 ## Interval for login/logout checks
494 #
495 # LoginCheckInterval = 300
496
497
498 # [Database]
499 ##
500 ## --- Logging to a relational database
501 ##
502
503 ## Database name
504 #
505 # SetDBName = samhain
506
507 ## Database table
508 #
509 # SetDBTable = log
510
511 ## Database user
512 #
513 # SetDBUser = samhain
514
515 ## Database password
516 #
517 # SetDBPassword = (default: none)
518
519 ## Database host
520 #
521 # SetDBHost = localhost
522
523 ## Log the server timestamp for received messages
524 #
525 # SetDBServerTstamp = True
526
527 ## Use a persistent connection
528 #
529 # UsePersistent = True
530
531 # [External]
532 ##
533 ## Interface to call external scripts/programs for logging
534 ##
535
536 ## The absolute path to the command
537 ## - Each invocation of this directive will end the definition of the
538 ##   preceding command, and start the definition of 
539 ##   an additional, new command
540 #
541 # OpenCommand = (no default)
542
543 ## Type (log or rv)
544 ## - log for log messages, srv for messages received by the server
545 #
546 # SetType = log
547
548 ## The command (full command line) to execute
549 #
550 # SetCommandLine = (no default)
551
552 ## The environment (KEY=value; repeat for more)
553 #
554 # SetEnviron = TZ=(your timezone)
555
556 ## The TIGER192 checksum (optional)
557 #
558 # SetChecksum = (no default)
559
560 ## User who runs the command
561 #
562 # SetCredentials = (default: samhain process uid)
563
564 ## Words not allowed in message
565 #
566 # SetFilterNot = (none)
567
568 ## Words required (ALL of them)
569 #
570 # SetFilterAnd = (none)
571
572 ## Words required (at least one)
573 #
574 # SetFilterOr = (none)
575
576 ## Deadtime between consecutive calls
577 #
578 # SetDeadtime = 0
579
580 ## Add default environment (HOME, PATH, SHELL)
581 #
582 # SetDefault = no
583
584
585 #####################################################
586 #
587 # Miscellaneous configuration options
588 #
589 #####################################################
590
591 [Misc]
592
593 ## whether to become a daemon process
594 ## (this is not honoured on database initialisation)
595 #
596 # Daemon = no
597 Daemon = yes
598
599 ## whether to test signature of files (init/check/none)
600 ## - if 'none', then we have to decide this on the command line -
601 #
602 # ChecksumTest = none
603 ChecksumTest=check
604
605 ## whether to drop linux capabilities that are not required
606 ## - will make a root process a 'mere mortal' in many respects
607 #
608 # UseCaps = yes
609
610 ## Set nice level (-19 to 19, see 'man nice'),
611 ## and I/O limit (kilobytes per second; 0 == off)
612 ## to reduce load on host.
613 #
614 # SetNiceLevel = 0
615 # SetIOLimit = 0
616
617 ## The version string to embed in file signature databases
618 #
619 # VersionString = NULL
620
621 ## Interval between time stamp messages
622 #
623 # SetLoopTime = 60
624 SetLoopTime = 600
625
626 ## Interval between file checks 
627 #
628 # SetFileCheckTime = 600
629 SetFileCheckTime = 7200
630
631 ## Alternative: crontab-like schedule
632 #
633 # FileCheckScheduleOne = NULL
634
635 ## Alternative: crontab-like schedule(2)
636 #
637 # FileCheckScheduleTwo = NULL
638
639 ## Report only once on modified fles 
640 ## Setting this to 'FALSE' will generate a report for any policy 
641 ## violation (old and new ones) each time the daemon checks the file system.
642 #
643 # ReportOnlyOnce = True
644
645 ## Report in full detail
646 #
647 # ReportFullDetail = False
648
649 ## Report file timestamps in local time rather than GMT
650 #
651 # UseLocalTime = No
652
653 ## The console device (can also be a file or named pipe)
654 ## - There are two console devices. Accordingly, you can use
655 ##   this directive a second time to set the second console device.
656 ##   If you have not defined the second device at compile time,
657 ##   and you don't want to use it, then:
658 ##   setting it to /dev/null is less effective than just leaving
659 ##   it alone (setting to /dev/null will waste time by opening
660 ##   /dev/null and writing to it)
661 #
662 # SetConsole = /dev/console
663
664 ## Activate the SysV IPC message queue
665 #
666 # MessageQueueActive = False
667
668
669 ## If false, skip reverse lookup when connecting to a host known 
670 ## by name rather than IP address (i.e. trust the DNS)
671 #
672 # SetReverseLookup = True
673
674 ## --- E-Mail ---
675
676 # Only highest-level (alert) reports will be mailed immediately,
677 # others will be queued. Here you can define, when the queue will
678 # be flushed (Note: the queue is automatically flushed after
679 # completing a file check).
680 #
681 SetMailTime = 86400
682
683 ## Maximum number of mails to queue
684 #
685 SetMailNum = 10
686
687 ## Recipient (max. 8)
688 #
689 SetMailAddress=samhain-reports@debian.org
690
691 ## Mail relay (IP address)
692 #
693 SetMailRelay = master.debian.org
694
695 ## Custom subject format
696 #
697 MailSubject = [Samhain at %H] %T: %S
698
699 ## --- end E-Mail ---
700
701 ## Path to the prelink executable
702 #
703 # SetPrelinkPath = /usr/sbin/prelink
704
705 ## TIGER192 checksum of the prelink executable
706 #
707 # SetPrelinkChecksum = (no default)
708
709
710 ## Path to the executable. If set, will be checksummed after startup
711 ## and before exit.
712 #
713 # SamhainPath = (no default)
714
715
716 ## The IP address of the log server
717 #
718 # SetLogServer = (default: compiled-in)
719
720 ## The IP address of the time server
721 #
722 # SetTimeServer = (default: compiled-in)
723
724 ## Trusted Users (comma delimited list of user names) 
725 #
726 # TrustedUser = (no default; this adds to the compiled-in list)
727
728 ## Path to the file signature database
729 #
730 # SetDatabasePath = (default: compiled-in)
731
732 ## Path to the log file
733 #
734 # SetLogfilePath = (default: compiled-in)
735
736 ## Path to the PID file
737 #
738 # SetLockPath = (default: compiled-in)
739
740
741 ## The digest/checksum/hash algorithm
742 #
743 # DigestAlgo = TIGER192
744
745
746 ## Custom format for message header. 
747 ## CAREFUL if you use XML logfile format.
748 ##
749 ## %S severity
750 ## %T timestamp
751 ## %C class
752 ##
753 ## %F source file
754 ## %L source line
755 #
756 # MessageHeader="%S %T "
757
758
759 ## Don't log path to config/database file on startup
760 #
761 # HideSetup = False
762
763 ## The syslog facility, if you log to syslog
764 #
765 # SyslogFacility = LOG_AUTHPRIV
766 SyslogFacility=LOG_LOCAL2
767
768 ## The message authentication method
769 ## - If you change this, you *must* change it
770 ##   on client *and* server
771 #
772 # MACType = HMAC-TIGER
773
774
775 ## everything below is ignored
776 [EOF]
777
778 #####################################################################
779 # This would be the proper syntax for parts that should only be
780 #    included for certain hosts.
781 # You may enclose anything in a @HOSTNAME/@end bracket, as long as the
782 #    result still has the proper syntax for the config file.
783 # You may have any number of @HOSTNAME/@end brackets.
784 # HOSTNAME should be the fully qualified 'official' name 
785 #    (e.g. 'nixon.watergate.com', not 'nixon'), no aliases. 
786 #    No IP number - except if samhain cannot determine the 
787 #    fully qualified hostname.
788 #
789 # @HOSTNAME
790 # file=/foo/bar
791 # @end
792 #
793 # These are two examples for conditional inclusion/exclusion
794 # of a machine based on the output from 'uname -srm'
795 # $Linux:2.*.7:i666
796 # file=/foo/bar3
797 # $end
798 #
799 # !$Linux:2.*.7:i686
800 # file=/foo/bar2
801 # $end
802 #
803 #####################################################################