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
6 #####################################################################
8 # Configuration file template for samhain.
10 #####################################################################
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
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).
22 #####################################################################
24 # SETUP for file system checking:
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).
35 #####################################################################
37 #####################################################################
39 # Files are defined with: file = /absolute/path
41 # Directories are defined with: dir = /absolute/path
42 # or with an optional recursion depth (N <= 99): dir = N/absolute/path
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.):
48 # dir = /some/directory
50 # file = /some/directory
52 # You can use shell-style globbing patterns, like: file = /path/foo*
54 ######################################################################
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
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)
73 ## for these files, only changes in permissions and ownership are checked
76 file=/etc/ssh_random_seed
81 file=/etc/passwd.backup
82 file=/etc/shadow.backup
83 file=/etc/postfix/prng_exch
87 file=/etc/lvm/cache/.cache
88 file=/etc/network/run/ifstate
89 file=/var/state/samhain/samhain_file
90 file=/etc/bind/zones/db.debian.net
92 <% if hostname == "geo1" || hostname == "geo2" || hostname == "geo3" -%>
94 file=/etc/bind/named.conf.acl
95 file=/etc/bind/named.conf.options
96 file=/etc/bind/named.conf.local
97 file=/etc/bind/geodns/named.conf.geo
98 file=/etc/bind/geodns/recvconf.files
103 # There are files in /etc that might change, thus changing the directory
104 # timestamps. Put it here as 'file', and in the ReadOnly section as 'dir'.
108 file=/etc/network/run
110 file=/etc/spamassassin/sa-update-keys
112 # These are the directories for the files we handle with puppet
113 file=/etc/apache2/conf.d
119 file=/etc/apt/apt.conf.d
120 file=/etc/apt/sources.list.d
122 file=/etc/logrotate.d
124 file=/etc/nagios/nrpe.d
125 file=/etc/nagios/obsolete-packages-ignore.d
126 file=/etc/bind/geodns
129 when "spohr.debian.org": extradir="file=/etc/nagios3/puppetconf.d
131 else extradir="file=/etc/puppet"
136 file=/usr/lib/nagios/plugins
139 file=/etc/monit/monit.d
147 ## for these files, changes in signature, timestamps, and size are ignored
154 #####################################################################
156 # This would be the proper syntax for parts that should only be
157 # included for certain hosts.
158 # You may enclose anything in a @HOSTNAME/@end bracket, as long as the
159 # result still has the proper syntax for the config file.
160 # You may have any number of @HOSTNAME/@end brackets.
161 # HOSTNAME should be the fully qualified 'official' name
162 # (e.g. 'nixon.watergate.com', not 'nixon'), no aliases.
163 # No IP number - except if samhain cannot determine the
164 # fully qualified hostname.
170 # These are two examples for conditional inclusion/exclusion
171 # of a machine based on the output from 'uname -srm'
181 #####################################################################
185 ## for these files, changes in signature, timestamps, and increase in size
189 file=/var/log/messages
191 file=/var/log/faillog
192 file=/var/log/auth.log
193 file=/var/log/daemon.log
194 file=/var/log/user.log
195 file=/var/log/kern.log
201 ## for these files, no modifications are reported
203 ## This file might be created or removed by the system sometimes.
205 file=/etc/resolv.conf.pcmcia.save
207 file=/etc/postfix/debian.db
208 file=/etc/postfix/debian
209 file=/etc/ssh/ssh_known_hosts
210 file=/etc/ssh/ssh-rsa-shadow
211 file=/var/lib/misc/ssh-rsa-shadow
212 file=/etc/.da-backup.trace
213 file=/etc/postfix/debianhosts
214 file=/etc/postfix/debianhosts.db
216 file=/etc/blkid.tab.old
217 file=/etc/resolv.conf.dhclient-new
219 # We handle these files with puppet - please to not be bothering us
222 file=/etc/samhain/samhainrc
223 file=/etc/munin/munin-node.conf
224 file=/etc/userdir-ldap.confc
225 file=/etc/exim4/blacklist
226 file=/etc/exim4/host_blacklist
227 file=/etc/exim4/callout_users
228 file=/etc/exim4/exim4.conf
229 file=/etc/exim4/grey_users
230 file=/etc/exim4/helo-check
231 file=/etc/exim4/locals
232 file=/etc/exim4/localusers
233 file=/etc/exim4/manualroute
234 file=/etc/exim4/rbllist
235 file=/etc/exim4/rcpthosts
236 file=/etc/exim4/rhsbllist
237 file=/etc/exim4/virtualdomains
238 file=/etc/exim4/whitelist
239 file=/etc/exim4/local-auto.conf
240 file=/etc/exim4/local-settings.conf
241 file=/etc/exim4/ssl/ca.crt
242 file=/etc/exim4/ssl/ca.crl
243 file=/etc/exim4/ssl/thishost.crt
244 file=/etc/exim4/ssl/thishost.key
245 file=/etc/ssh/ssh_config
246 file=/etc/ssh/sshd_config
249 if not nodeinfo['heavy_exim'].empty?
251 file=/etc/exim4/surbl_whitelist.txt
252 file=/etc/exim4/exim_surbl.pl
253 file=/etc/exim4/ccTLD.txt
254 file=/etc/clamav-unofficial-sigs.conf
255 file=/etc/clamav-unofficial-sigs.dsa.conf
260 file=/etc/apache2/conf.d/ressource-limits
261 file=/etc/apt/preferences
262 file=/etc/apt/sources.list.d/volatile.list
263 file=/etc/apt/sources.list.d/security.list
264 file=/etc/apt/sources.list.d/buildd.list
265 file=/etc/apt/sources.list.d/debian.org.list
266 file=/etc/apt/sources.list.d/debian.restricted.list
267 file=/etc/apt/sources.list.d/debian.list
268 file=/etc/apt/sources.list.d/backports.org.list
269 file=/etc/apt/apt.conf.d/local-recommends
270 file=/etc/apt/apt.conf.d/local-pdiffs
271 file=/etc/puppet/puppet.conf
272 file=/etc/default/puppet
273 file=/etc/default/postgrey
274 file=/etc/logrotate.d/exim4-paniclog
275 file=/etc/logrotate.d/exim4-base
276 file=/etc/logrotate.d/syslog-ng
277 file=/etc/syslog-ng/syslog-ng.conf
278 file=/usr/sbin/dsa-update-apt-status
279 file=/usr/sbin/dsa-update-samhain-status
280 file=/etc/nagios/nrpe.d/nrpe_dsa.cfg
281 file=/etc/nagios/nrpe.d/debianorg.cfg
282 file=/etc/nagios/obsolete-packages-ignore
283 file=/etc/nagios/obsolete-packages-ignore.d/hostspecific
284 file=/usr/lib/nagios/plugins/dsa-check-packages
285 file=/usr/lib/nagios/plugins/dsa-check-soas
286 file=/usr/lib/nagios/plugins/dsa-check-mirrorsync
287 file=/usr/lib/nagios/plugins/dsa-check-samhain
288 file=/usr/lib/nagios/plugins/dsa-check-statusfile
289 file=/usr/lib/nagios/plugins/dsa-check-dabackup-server
290 file=/usr/lib/nagios/plugins/dsa-check-config
291 file=/usr/lib/nagios/plugins/dsa-check-hpacucli
292 file=/usr/lib/nagios/plugins/dsa-check-raid-mpt
293 file=/usr/lib/nagios/plugins/dsa-check-puppet
294 file=/usr/lib/nagios/plugins/dsa-check-running-kernel
295 file=/usr/lib/nagios/plugins/dsa-check-raid-3ware
296 file=/usr/lib/nagios/plugins/dsa-check-dabackup
297 file=/usr/lib/nagios/plugins/dsa-check-raid-dac960
298 file=/usr/lib/nagios/plugins/dsa-check-udldap-freshness
299 file=/usr/lib/nagios/plugins/dsa-check-raid-areca
300 file=/usr/lib/nagios/plugins/dsa-check-raid-sw
301 file=/usr/lib/nagios/plugins/dsa-update-samhain-status
303 file=/etc/sysctl.d/mmap_min_addr.conf
305 file=/etc/monit/monitrc
306 file=/etc/monit/monit.d/01puppet
307 file=/etc/monit/monit.d/00debian.org
308 file=/etc/cron.d/dsa-puppet-stuff
311 when "spohr.debian.org": extrafiles="file=/etc/nagios3/puppetconf.d/auto-hostgroups.cfg
312 file=/etc/nagios3/puppetconf.d/auto-hosts.cfg
313 file=/etc/nagios3/puppetconf.d/auto-services.cfg
314 file=/etc/nagios3/puppetconf.d/auto-dependencies.cfg
315 file=/etc/nagios3/puppetconf.d/auto-hostextinfo.cfg
316 file=/etc/nagios3/puppetconf.d/auto-serviceextinfo.cfg"
317 when "handel.debian.org": extrafiles="dir=8/etc/puppet"
318 when "dijkstra.debian.org": extrafiles="dir=4/etc/dsa-kvm"
319 when /geo[123].debian.org/: extrafiles="dir=1/etc/bind/geodns"
326 ## for these files, all modifications (even access time) are reported
327 ## - you may create some interesting-looking file (like /etc/safe_passwd),
328 ## just to watch whether someone will access it ...
333 ## Use for prelinked files or directories holding them
339 ## for these files, only access time is ignored
345 # SuSE (old) has the boot init scripts in /sbin/init.d/*,
346 # so we go 3 levels deep
353 # RedHat and Debian have the bootinit scripts in /etc/init.d/* or /etc/rc.d/*,
354 # so we go 3 levels deep there too
358 # Various directories / files that may include / be SUID/SGID binaries
361 file=/usr/lib/pt_chown
362 # X11, in Debian X7 this is now a symlink
364 #dir=/usr/X11R6/lib/X11/xmcd/bin
366 #file=/usr/lib/apache/suexec
367 #file=/usr/lib/apache/suexec.disabled
374 ## User0 and User1 are sections for files/dirs with user-definable checking
380 ## Here you can assign severities to policy violations.
381 ## If this severity exceeds the treshold of a log facility (see below),
382 ## a policy violation will be logged to that facility.
384 ## Severity for verification failures.
386 # SeverityReadOnly=crit
387 # SeverityLogFiles=crit
388 # SeverityGrowingLogs=crit
389 # SeverityIgnoreNone=crit
390 # SeverityAttributes=crit
395 SeverityReadOnly=crit
396 SeverityLogFiles=crit
397 SeverityGrowingLogs=warn
398 SeverityIgnoreNone=crit
399 SeverityAttributes=crit
403 ## We have a file in IgnoreAll that might or might not be present.
404 ## Setting the severity to 'info' prevents messages about deleted/new file.
406 # SeverityIgnoreAll=crit
407 SeverityIgnoreAll=info
409 ## Files : file access problems
412 ## Dirs : directory access problems
415 ## Names : suspect (non-printable) characters in a pathname
426 ## Switch on/OFF log facilities and set their threshold severity
428 ## Values: debug, info, notice, warn, mark, err, crit, alert, none.
429 ## 'mark' is used for timestamps.
432 ## Use 'none' to SWITCH OFF a log facility
434 ## By default, everything equal to and above the threshold is logged.
435 ## The specifiers '*', '!', and '=' are interpreted as
436 ## 'all', 'all but', and 'only', respectively (like syslogd(8) does,
437 ## at least on Linux). Examples:
439 ## MailSeverity=!warn
440 ## MailSeverity==crit
456 # SyslogSeverity=none
458 ## Remote server (yule)
460 # ExportSeverity=none
462 ## External script or program
464 # ExternalSeverity = none
466 ## Logging to a database
468 # DatabaseSeverity = none
481 #####################################################
485 #####################################################
489 ## --- Check the filesystem for SUID/SGID binaries
494 # SuidCheckActive = yes
496 ## Interval for check (seconds)
498 # SuidCheckInterval = 7200
500 ## Alternative: crontab-like schedule
502 # SuidCheckSchedule = NULL
504 ## Directory to exclude
506 # SuidCheckExclude = NULL
508 ## Limit on files per second (0 == no limit)
512 ## Alternative: yield after every file
514 # SuidCheckYield = no
516 ## Severity of a detection
518 # SeveritySuidCheck = crit
520 ## Quarantine SUID/SGID files if found
522 # SuidCheckQuarantineFiles = yes
524 ## Method for Quarantining files:
525 # 0 - Delete or truncate the file.
526 # 1 - Remove SUID/SGID permissions from file.
527 # 2 - Move SUID/SGID file to quarantine dir.
529 # SuidCheckQuarantineMethod = 0
531 ## For method 1 and 3, really delete instead of truncating
533 # SuidCheckQuarantineDelete = yes
537 ## --- Check for loadable kernel module rootkits (Linux/FreeBSD only)
542 KernelCheckActive = True
544 ## Check interval (seconds); btw., the check is VERY fast
546 # KernelCheckInterval = 300
550 # SeverityKernel = crit
555 ## --- Logging of login/logout events
560 LoginCheckActive = True
562 ## Severity for logins, multiple logins, logouts
565 # SeverityLoginMulti=warn
566 # SeverityLogout=info
568 ## Interval for login/logout checks
570 # LoginCheckInterval = 300
575 ## --- Logging to a relational database
580 # SetDBName = samhain
588 # SetDBUser = samhain
592 # SetDBPassword = (default: none)
596 # SetDBHost = localhost
598 ## Log the server timestamp for received messages
600 # SetDBServerTstamp = True
602 ## Use a persistent connection
604 # UsePersistent = True
608 ## Interface to call external scripts/programs for logging
611 ## The absolute path to the command
612 ## - Each invocation of this directive will end the definition of the
613 ## preceding command, and start the definition of
614 ## an additional, new command
616 # OpenCommand = (no default)
619 ## - log for log messages, srv for messages received by the server
623 ## The command (full command line) to execute
625 # SetCommandLine = (no default)
627 ## The environment (KEY=value; repeat for more)
629 # SetEnviron = TZ=(your timezone)
631 ## The TIGER192 checksum (optional)
633 # SetChecksum = (no default)
635 ## User who runs the command
637 # SetCredentials = (default: samhain process uid)
639 ## Words not allowed in message
641 # SetFilterNot = (none)
643 ## Words required (ALL of them)
645 # SetFilterAnd = (none)
647 ## Words required (at least one)
649 # SetFilterOr = (none)
651 ## Deadtime between consecutive calls
655 ## Add default environment (HOME, PATH, SHELL)
660 #####################################################
662 # Miscellaneous configuration options
664 #####################################################
668 ## whether to become a daemon process
669 ## (this is not honoured on database initialisation)
674 ## whether to test signature of files (init/check/none)
675 ## - if 'none', then we have to decide this on the command line -
677 # ChecksumTest = none
680 ## whether to drop linux capabilities that are not required
681 ## - will make a root process a 'mere mortal' in many respects
685 ## Set nice level (-19 to 19, see 'man nice'),
686 ## and I/O limit (kilobytes per second; 0 == off)
687 ## to reduce load on host.
692 ## The version string to embed in file signature databases
694 # VersionString = NULL
696 ## Interval between time stamp messages
701 ## Interval between file checks
703 # SetFileCheckTime = 600
704 SetFileCheckTime = 7200
706 ## Alternative: crontab-like schedule
708 # FileCheckScheduleOne = NULL
710 ## Alternative: crontab-like schedule(2)
712 # FileCheckScheduleTwo = NULL
714 ## Report only once on modified fles
715 ## Setting this to 'FALSE' will generate a report for any policy
716 ## violation (old and new ones) each time the daemon checks the file system.
718 # ReportOnlyOnce = True
720 ## Report in full detail
722 # ReportFullDetail = False
724 ## Report file timestamps in local time rather than GMT
728 ## The console device (can also be a file or named pipe)
729 ## - There are two console devices. Accordingly, you can use
730 ## this directive a second time to set the second console device.
731 ## If you have not defined the second device at compile time,
732 ## and you don't want to use it, then:
733 ## setting it to /dev/null is less effective than just leaving
734 ## it alone (setting to /dev/null will waste time by opening
735 ## /dev/null and writing to it)
737 # SetConsole = /dev/console
739 ## Activate the SysV IPC message queue
741 # MessageQueueActive = False
744 ## If false, skip reverse lookup when connecting to a host known
745 ## by name rather than IP address (i.e. trust the DNS)
747 # SetReverseLookup = True
751 # Only highest-level (alert) reports will be mailed immediately,
752 # others will be queued. Here you can define, when the queue will
753 # be flushed (Note: the queue is automatically flushed after
754 # completing a file check).
758 ## Maximum number of mails to queue
762 ## Recipient (max. 8)
764 SetMailAddress=samhain-reports@debian.org
766 ## Mail relay (IP address)
769 if not nodeinfo['smarthost'].empty?
771 SetMailRelay = localhost
775 SetMailRelay = master.debian.org
780 ## Custom subject format
782 MailSubject = [Samhain at %H] %T: %S
784 ## --- end E-Mail ---
786 ## Path to the prelink executable
788 # SetPrelinkPath = /usr/sbin/prelink
790 ## TIGER192 checksum of the prelink executable
792 # SetPrelinkChecksum = (no default)
795 ## Path to the executable. If set, will be checksummed after startup
798 # SamhainPath = (no default)
801 ## The IP address of the log server
803 # SetLogServer = (default: compiled-in)
805 ## The IP address of the time server
807 # SetTimeServer = (default: compiled-in)
809 ## Trusted Users (comma delimited list of user names)
811 # TrustedUser = (no default; this adds to the compiled-in list)
813 ## Path to the file signature database
815 # SetDatabasePath = (default: compiled-in)
817 ## Path to the log file
819 # SetLogfilePath = (default: compiled-in)
821 ## Path to the PID file
823 # SetLockPath = (default: compiled-in)
826 ## The digest/checksum/hash algorithm
828 # DigestAlgo = TIGER192
831 ## Custom format for message header.
832 ## CAREFUL if you use XML logfile format.
841 # MessageHeader="%S %T "
844 ## Don't log path to config/database file on startup
848 ## The syslog facility, if you log to syslog
850 # SyslogFacility = LOG_AUTHPRIV
851 SyslogFacility=LOG_LOCAL2
853 ## The message authentication method
854 ## - If you change this, you *must* change it
855 ## on client *and* server
857 # MACType = HMAC-TIGER
860 ## everything below is ignored
863 #####################################################################
864 # This would be the proper syntax for parts that should only be
865 # included for certain hosts.
866 # You may enclose anything in a @HOSTNAME/@end bracket, as long as the
867 # result still has the proper syntax for the config file.
868 # You may have any number of @HOSTNAME/@end brackets.
869 # HOSTNAME should be the fully qualified 'official' name
870 # (e.g. 'nixon.watergate.com', not 'nixon'), no aliases.
871 # No IP number - except if samhain cannot determine the
872 # fully qualified hostname.
878 # These are two examples for conditional inclusion/exclusion
879 # of a machine based on the output from 'uname -srm'
888 #####################################################################