server: gitea: fail2ban fix
This commit is contained in:
parent
1771fba57b
commit
6059c3c0ba
@ -116,14 +116,15 @@
|
|||||||
fail2ban = {
|
fail2ban = {
|
||||||
enable = true;
|
enable = true;
|
||||||
maxretry = 5;
|
maxretry = 5;
|
||||||
|
extraSettings = {
|
||||||
|
findtime = "15m";
|
||||||
|
bantime = "1h";
|
||||||
|
};
|
||||||
jails = {
|
jails = {
|
||||||
gitea = ''
|
gitea = ''
|
||||||
enabled = true
|
enabled = true
|
||||||
filter = gitea
|
filter = gitea
|
||||||
backend = systemd
|
backend = systemd
|
||||||
maxretry = 10
|
|
||||||
findtime = 3600
|
|
||||||
bantime = 900
|
|
||||||
action = iptables-allports
|
action = iptables-allports
|
||||||
'';
|
'';
|
||||||
};
|
};
|
||||||
|
@ -1,3 +1,5 @@
|
|||||||
[Definition]
|
[Definition]
|
||||||
failregex = .*(Failed authentication attempt|invalid credentials|Attempted access of unknown user).* from <HOST>
|
failregex = .*(Failed authentication attempt|invalid credentials|Attempted access of unknown user).* from <HOST>
|
||||||
ignoreregex =
|
ignoreregex =
|
||||||
|
#journalmatch = _SYSTEMD_UNIT=gitea.servie
|
||||||
|
journalmatch =
|
||||||
|
Loading…
Reference in New Issue
Block a user