Différences

Ci-dessous, les différences entre deux révisions de la page.

Lien vers cette vue comparative

Les deux révisions précédentesRévision précédente
Prochaine révision
Révision précédente
pratique:informatique:parefeu:fail2ban [30/05/2024 08:20] – ↷ Page déplacée de pratique:informatique:fail2ban à pratique:informatique:parefeu:fail2ban Zatalyzpratique:informatique:parefeu:fail2ban [26/08/2026 11:44] (Version actuelle) – [Fail2ban] Zatalyz
Ligne 44: Ligne 44:
 # Si on ban quelque part, c'est partout (en principe) # Si on ban quelque part, c'est partout (en principe)
 banaction = iptables-multiport banaction = iptables-multiport
 +
 +# Eviter de s'auto-bannir
 +# local
 +ignoreip = 127.0.0.1/8 ::1                          
 +# Moi
 +ignoreip = ipv4 ipv6
 +
  
 ## Les services surveillés, dits "jail" ## Les services surveillés, dits "jail"
Ligne 54: Ligne 61:
 enabled = true enabled = true
 [apache-badbots] [apache-badbots]
-enabled = true 
-[apache-noscript] 
-enabled = true 
-[apache-overflows] 
-enabled = true 
-[apache-nohome] 
 enabled = true enabled = true
 [apache-botsearch] [apache-botsearch]
 +enabled = true
 +[apache-common]
 enabled = true enabled = true
 [apache-fakegooglebot] [apache-fakegooglebot]
 enabled = true enabled = true
 [apache-modsecurity] [apache-modsecurity]
 +enabled = true
 +[apache-noscript]
 +enabled = true
 +[apache-overflows]
 +enabled = true
 +[apache-nohome]
 enabled = true enabled = true
 [apache-shellshock] [apache-shellshock]
Ligne 87: Ligne 96:
   fail2ban-server -t   fail2ban-server -t
   systemctl restart fail2ban   systemctl restart fail2ban
-  + 
 +==== Mise à jour nftables ==== 
 +Pour utiliser fail2ban avec nftables, et utiliser les logs de journalctl, le début du fichier doit ressemble à ceci :  
 +<code> 
 +[DEFAULT] 
 +[...] 
 +banaction = nftables-multiport 
 +banaction_allports = nftables-allports 
 +backend = systemd 
 + 
 +</code>
 ==== Commandes fail2ban utilisées régulièrement ==== ==== Commandes fail2ban utilisées régulièrement ====
   * Liste des jails : ''fail2ban-client status''   * Liste des jails : ''fail2ban-client status''
pratique/informatique/parefeu/fail2ban.1717050041.txt.gz · Dernière modification : 30/05/2024 08:20 de Zatalyz