bloquer_les_attaques_en_force_brute_avec_fail2ban
Différences
Ci-dessous, les différences entre deux révisions de la page.
| Les deux révisions précédentesRévision précédenteProchaine révision | Révision précédente | ||
| bloquer_les_attaques_en_force_brute_avec_fail2ban [2026/05/10 12:19] – [Bannissement incrémental] Flaz | bloquer_les_attaques_en_force_brute_avec_fail2ban [2026/05/10 14:16] (Version actuelle) – [Ne pas bannir] Flaz | ||
|---|---|---|---|
| Ligne 24: | Ligne 24: | ||
| Avant d' | Avant d' | ||
| - | Pour ce faire, on utilise la commande // | + | Pour ce faire, on utilise la commande |
| < | < | ||
| Ligne 78: | Ligne 78: | ||
| ===== Idées de filtres ===== | ===== Idées de filtres ===== | ||
| + | |||
| + | ==== apache-badbots ==== | ||
| + | Le filtre fourni avec Fail2ban contient une liste prédéfinie de robots malveillants. Pour compléter cette liste sans qu' | ||
| + | |||
| + | <code - apache-badbots-custom.local> | ||
| + | [INCLUDES] | ||
| + | before = apache-badbots.conf | ||
| + | [Definition] | ||
| + | mybotcustom = Bytespider|MJ12bot|SeekportBot|serpstatbot|Barkrowler|YandexBot|AhrefsBot|DotBot|MojeekBot|ZoominfoBot|PetalBot|serpstatbot|BitSightBot|wpbot|WellKnownBot|BLEXBot|AwarioBot|ImagesiftBot|Dataprovider|Amazonbot|GPTBot|OAI-SearchBot|ChatGPT-User|ClaudeBot|SemrushBot|externalhit_uatext|SERankingBacklinksBot | ||
| + | failregex = ^< | ||
| + | </ | ||
| + | |||
| ==== apache-ratelimit ==== | ==== apache-ratelimit ==== | ||
| L' | L' | ||
| - | Attention à l' | + | Attention à l' |
| + | |||
| + | Source : [[https:// | ||
| + | |||
| + | ===== Idées d' | ||
| + | ==== Ne pas bannir ==== | ||
| + | Une des actions envisageable est de signaler un bannissement potentiel sans effectuer le bannissement. C'est tout à fait possible mais le fichier jail.conf ne définit pas le raccourci d' | ||
| + | |||
| + | Un tel raccourci se déduit facilement d'un raccourci existant. Par exemple : | ||
| + | < | ||
| + | # ban & send an e-mail with whois report to the destemail. | ||
| + | action_mw = %(action_)s | ||
| + | %(mta)s-whois[sender=" | ||
| + | </ | ||
| + | devient, par simple suppression de l' | ||
| + | < | ||
| + | # send an e-mail with whois report to the destemail. | ||
| + | action_noban_mw = %(mta)s-whois[sender=" | ||
| + | </ | ||
| + | que l'on pourra ajouter dans la section // | ||
bloquer_les_attaques_en_force_brute_avec_fail2ban.1778415559.txt.gz · Dernière modification : de Flaz
