4 banaction = lib.mkDefault "nftables-multiport";
5 banaction-allports = lib.mkDefault "nftables-allports";
6 packageFirewall = lib.mkDefault pkgs.nftables;
10 formula = "ban.Time * (1 << min(ban.Count, 20)) * banFactor";
17 systemd.services.nftables.postStart = '' systemctl reload fail2ban '';
19 services.openssh.settings.LogLevel = "VERBOSE";
20 services.postgresql.logLinePrefix = "%h ";
21 environment.etc."fail2ban/action.d/nftables-common.local".text = ''
25 environment.etc."fail2ban/filter.d/postgresql.local".text = ''
29 _daemon = postgresql-start
31 journalmatch = _SYSTEMD_UNIT=postgresql.service + _COMM=postgres
32 prefregex = ^<F-MLFID>%(__prefix_line)s</F-MLFID><F-CONTENT>.+</F-CONTENT>$
33 failregex = ^<HOST>\s+FATAL:\s*no pg_hba.conf entry for host.+$
34 ^<HOST>\s+FATAL:\s*no PostgreSQL user name specified in startup packet.+$
35 ^<HOST>\s+FATAL:\s*password authentication failed for user.+$
36 ^<HOST>\s+FATAL:\s*unsupported frontend protocol.+$
38 #ignoreregex = duration: