Стоит 10.04 server установил апач2 решил добавить мониторинг fail2ban для апача так как появились в логах апача строки
[Wed Jan 12 13:34:25 2011] [error] [client *.*.112.168] File does not exist: /var/www/PHPMYADMIN
[Wed Jan 12 13:34:26 2011] [error] [client *.*.112.168] File does not exist: /var/www/PMA
[Wed Jan 12 13:34:26 2011] [error] [client *.*.112.168] File does not exist: /var/www/admin
[Wed Jan 12 13:34:27 2011] [error] [client *.*.112.168] File does not exist: /var/www/mysql
в jail.conf выставил:
[apache-nohome]
enabled = true
port<--> = http,https
filter<> = apache-nohome
logpath = /var/log/apache2/error.log
maxretry = 4
А это apache-nohome.conf
Файл: apache-n~me.conf Строка 1 Позиция 0 628 байт 100%
# Fail2Ban configuration file
#
# Author: Yaroslav O. Halchenko <debian@onerussian.com>
#
# $Revision: 716 $
#
[Definition]
# Option: failregex
# Notes.: regex to match failures to find a home directory on a server, which
# became popular last days. Most often attacker just uses IP instead of
# domain name -- so expect to see them in generic error.log if you have
# per-domain log files.
# Values: TEXT
#
failregex = [[]client <HOST>[]] File does not exist: .*/~.*
# Option: ignoreregex
# Notes.: regex to ignore. If this regex matches, the line is ignored.
# Values: TEXT
#
ignoreregex =
При рестарте fail2ban появляються такие ошибки как бороться? Заранее спасибо.
2011-01-12 16:38:48,955 fail2ban.jail : INFO Jail 'apache-noscript' started
2011-01-12 16:38:48,959 fail2ban.jail : INFO Jail 'vsftpd' started
2011-01-12 16:38:48,965 fail2ban.jail : INFO Jail 'apache-nohome' started
2011-01-12 16:38:48,981 fail2ban.jail : INFO Jail 'named-refused-udp' started
2011-01-12 16:38:48,999 fail2ban.jail : INFO Jail 'ssh-ddos' started
2011-01-12 16:38:49,015 fail2ban.jail : INFO Jail 'apache-overflows' started
2011-01-12 16:38:49,030 fail2ban.jail : INFO Jail 'ssh' started
2011-01-12 16:38:49,043 fail2ban.actions.action: ERROR iptables -N fail2ban-apache-nohome
iptables -A fail2ban-apache-nohome -j RETURN
iptables -I INPUT -p tcp -m multiport --dports http,https -j fail2ban-apache-nohome returned 200
2011-01-12 16:38:49,059 fail2ban.jail : INFO Jail 'apache' started
2011-01-12 16:38:49,085 fail2ban.jail : INFO Jail 'named-refused-tcp' started
2011-01-12 16:38:49,105 fail2ban.actions.action: ERROR iptables -N fail2ban-apache-overflows
iptables -A fail2ban-apache-overflows -j RETURN
iptables -I INPUT -p tcp -m multiport --dports http,https -j fail2ban-apache-overflows returned 400