Defined Type: fail2ban::filter
- Defined in:
- manifests/filter.pp
Summary
Setup a filter for fail2banOverview
fail2ban/manifests/filter.pp
-
Copyright (C) 2014-2018 gabster@lelutin.ca
Filters are how fail2ban detects mischief in logs. They contain regular expressions that should catch bad activity and identify the IP that is doing this activity.
42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 |
# File 'manifests/filter.pp', line 42
define fail2ban::filter (
Array[String, 1] $failregexes,
Enum['present', 'absent'] $ensure = 'present',
Array[String, 0] $ignoreregexes = [],
Array[String, 0] $includes = [],
Array[String, 0] $includes_after = [],
Array[String, 0] $additional_defs = []
) {
include fail2ban::config
file { "/etc/fail2ban/filter.d/${name}.conf":
ensure => $ensure,
content => template('fail2ban/filter.erb'),
owner => 'root',
group => 0,
mode => '0644',
require => Class['fail2ban::config'],
notify => Class['fail2ban::service'],
}
}
|