Bug 25921 - Проблема взаимодействия fail2ban и iptables
Summary: Проблема взаимодействия fail2ban и iptables
Status: CLOSED FIXED
Alias: None
Product: Sisyphus
Classification: Development
Component: fail2ban (show other bugs)
Version: unstable
Hardware: all Linux
: P3 normal
Assignee: Grigory Ustinov
QA Contact: qa-sisyphus
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2011-07-18 13:03 MSK by Gulay Boris
Modified: 2011-08-02 07:39 MSK (History)
19 users (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Gulay Boris 2011-07-18 13:03:41 MSK
У меня не добавляются (или не удаляются) некоторые правила в iptables. В логе fail2ban при этом такие записи:

2011-07-18 11:54:59,966 fail2ban.actions.action: ERROR  iptables -N fail2ban-dovecot-imap
iptables -A fail2ban-dovecot-imap -j RETURN
iptables -I INPUT -p tcp --dport imap -j fail2ban-dovecot-imap returned 200
2011-07-18 11:54:59,976 fail2ban.actions.action: ERROR  iptables -N fail2ban-postfix-spam
iptables -A fail2ban-postfix-spam -j RETURN
iptables -I INPUT -p tcp --dport smtp -j fail2ban-postfix-spam returned 200
2011-07-18 12:47:56,355 fail2ban.jail   : INFO   Jail 'nginx' stopped
2011-07-18 12:47:57,425 fail2ban.jail   : INFO   Jail 'rcguard' stopped
2011-07-18 12:47:58,348 fail2ban.actions.action: ERROR  iptables -D INPUT -p tcp --dport imap -j fai
iptables -F fail2ban-dovecot-imap
iptables -X fail2ban-dovecot-imap returned 100

Очевидно, пощдобная проблема присутствует и в сизифе.
Мне помогло решение отсюда:
http://oschgan.com/drupal/index.php?q=node/52
Описанное изменение заметно замедляет запуск сервиса, но ошибки исчезают и правила добавляются/удаляются корректно. Предлагаю добавить соответствующий код в файл в нашем пакете.
Comment 1 Andrey Cherepanov 2011-07-18 18:02:08 MSK
Переношу на Sisyphus.
Comment 2 Repository Robot 2011-08-02 07:39:50 MSK
fail2ban-0.8.4-alt4.1 -> sisyphus:

* Tue Aug 02 2011 Eugeny A. Rostovtsev (REAL) <real at altlinux> 0.8.4-alt4.1
- Fixed interaction with fail2ban and iptables (ALT #25921)