Good evening,
Fail2Ban refuses to access the Nextcloud log file. The os used is Rocky Linux.
I followed the instructions in the Nextcloud documentation for configuration.
Do you know of a solution for this?
The output from systemctl status fail2ban.service:
fail2ban-server: ERROR Failed during configuration: Have not found any log file for nextcloud jail
The output from fail2ban-client status nextcloud:
ERROR Failed to access socket path: /var/run/fail2ban/fail2ban.sock. Is fail2ban running?
The nextcloud.local file in the jail.d folder:
[nextcloud]
backend = auto
enabled = true
port = 80,443
protocol = tcp
filter = nextcloud
maxretry = 3
bantime = 86400
findtime = 43200
logpath = /var/www/html/nextcloud/data/nextcloud.log
The nextcloud.conf file in the filter.d folder:
[Definition]
_groupsre = (?:(?:,?\s*"\w+":(?:"[^"]+"|\w+))*)
failregex = ^\{%(_groupsre)s,?\s*"remoteAddr":"<HOST>"%(_groupsre)s,?\s*"message":"Login failed:
^\{%(_groupsre)s,?\s*"remoteAddr":"<HOST>"%(_groupsre)s,?\s*"message":"Trusted domain error.
datepattern = ,?\s*"time"\s*:\s*"%%Y-%%m-%%d[T ]%%H:%%M:%%S(%%z)?"
Greeting
Sebby