Commit Graph
5 Commits
Author SHA1 Message Date
Clément Désiles 24502f543f fix(fail2ban): pass blocktype via banaction to override the ufw action default
jail-level blocktype is ignored (action [Init] wins); it must be
passed as banaction = ufw[blocktype=deny].
2026-09-05 16:57:45 +02:00
Clément Désiles 6355a9aae5 fix(fail2ban): ban via ufw deny (DROP) instead of reject
REJECT needs the nft_reject kernel extension, which is unavailable on
this Arch kernel (iptables-nft reports 'Extension REJECT revision 0
not supported'), so every ban silently failed. DROP works everywhere
and is quieter toward attackers.
2026-09-05 16:45:12 +02:00
Clément Désiles 40cc0efcf8 fix(fail2ban): use ProtectSystem=full so ufw can create its lock file
strict makes /run read-only, which blocks ufw's /run/ufw.lock and
cannot be whitelisted via ReadWritePaths (the file does not exist).
full still protects /usr and /etc while leaving /run and /var writable,
so only /etc/ufw needs an explicit write path.
2026-09-05 16:28:55 +02:00
Clément Désiles 120615c38f fix(fail2ban): start under ProtectSystem=strict hardening
- log to journald via fail2ban.local (logtarget is a fail2ban.conf option,
  not jail.local) so the server can start without /var/log write access
- create the socket dir via RuntimeDirectory=fail2ban instead of a
  non-creating ReadWritePaths entry
- add ufw write paths so bans persist under the read-only namespace
- manage override.conf unconditionally and restart on change
2026-09-05 16:21:49 +02:00
Clément Désiles c612cc7839 chore: first commit 2025-07-25 20:23:54 +02:00