Preparation for fail2ban script
This commit is contained in:
6
seqs/fail2ban/filter.d/ip-blacklist.conf
Normal file
6
seqs/fail2ban/filter.d/ip-blacklist.conf
Normal file
@@ -0,0 +1,6 @@
|
||||
[Definition]
|
||||
|
||||
failregex = ^<HOST> \[.*\]$
|
||||
|
||||
ignoreregex =
|
||||
|
4
seqs/fail2ban/filter.d/nextcloud.conf
Normal file
4
seqs/fail2ban/filter.d/nextcloud.conf
Normal file
@@ -0,0 +1,4 @@
|
||||
[Definition]
|
||||
|
||||
failregex = ^.*\"remoteAddr\":\"<HOST>\".*Trusted domain error.*$
|
||||
^.*\"remoteAddr\":\"<HOST>\".*Login failed:.*$
|
1
seqs/fail2ban/ip.blacklist.example
Normal file
1
seqs/fail2ban/ip.blacklist.example
Normal file
@@ -0,0 +1 @@
|
||||
37.49.224.142 [02/02/2019 09:00:00]
|
18
seqs/fail2ban/jail.d/ip-blacklist.conf
Normal file
18
seqs/fail2ban/jail.d/ip-blacklist.conf
Normal file
@@ -0,0 +1,18 @@
|
||||
[ip-blacklist]
|
||||
|
||||
enabled = true
|
||||
banaction = iptables-allports
|
||||
port = anyport
|
||||
filter = ip-blacklist
|
||||
logpath = /etc/fail2ban/ip.blacklist
|
||||
maxretry = 0
|
||||
#findtime = 15552000
|
||||
findtime = 600
|
||||
# infinite ban
|
||||
#bantime = -1
|
||||
# 1 day ban
|
||||
#bantime = 86400
|
||||
# 2 day ban
|
||||
bantime = 172800
|
||||
# 10 minute ban
|
||||
#bantime = 600
|
6
seqs/fail2ban/jail.d/mail.conf
Normal file
6
seqs/fail2ban/jail.d/mail.conf
Normal file
@@ -0,0 +1,6 @@
|
||||
[dovecot]
|
||||
enabled = true
|
||||
port = pop3,pop3s,imap,imaps
|
||||
filter = dovecot
|
||||
logpath = /var/log/mail.info
|
||||
maxretry = 3
|
8
seqs/fail2ban/jail.d/nextcloud.conf
Normal file
8
seqs/fail2ban/jail.d/nextcloud.conf
Normal file
@@ -0,0 +1,8 @@
|
||||
[nextcloud]
|
||||
enabled = true
|
||||
logpath = /var/nc_data/nextcloud.log
|
||||
port = http,https
|
||||
filter = nextcloud
|
||||
maxretry = 3
|
||||
# 1 day ban
|
||||
bantime = 86400
|
Reference in New Issue
Block a user