Код: Выделить всё
hostlist relay_from_hosts = 127.0.0.1/8 : 172.16.0.0/16 : 10.132.253.0/24 : 192.168.15.0/24
acl_check_rcpt:
warn set acl_m307 = -1
set acl_m308 = -1
warn set acl_m307 = ${lookup mysql{TEST_FOR_SPAM_EXISTS_USER_ALIAS}{$value}{0}}
hosts = !+relay_from_hosts
warn set acl_m308 = ${lookup mysql{TEST_FOR_SPAM_EXISTS_USER_MAILBOX}{$value}{0}}
hosts = !+relay_from_hosts
warn set acl_m309 = ${lookup mysql{TEST_FOR_SPAM_DEL_MAIL_STAT1}}
hosts = !+relay_from_hosts
warn set acl_m309 = -1
warn set acl_m309 = ${lookup mysql{TEST_FOR_SPAM_GET_MAIL_STAT}{$value}{0}}
log_message = "X-W-HS Host $sender_host_address get mailstat!"
hosts = !+relay_from_hosts
warn condition = ${if and { {eq{$acl_m307}{0}} {eq{$acl_m308}{0}} {eq{$acl_m309}{0}} } {yes}{no}}
set acl_m310 = ${lookup mysql{TEST_FOR_SPAM_INS_MAIL_STAT}}
log_message = "X-W-HS Host $sender_host_address insert mailstat!"
hosts = !+relay_from_hosts
warn condition = ${if and { {eq{$acl_m307}{0}} {eq{$acl_m308}{0}} {>{$acl_m309}{0}} {<{$acl_m309}{25}} } {yes}{no}}
set acl_m310 = ${lookup mysql{TEST_FOR_SPAM_UPD_MAIL_STAT}}
log_message = "X-W-HS Host $sender_host_address update mailstat!"
hosts = !+relay_from_hosts
warn condition = ${if >={$acl_m309}{25} {true}{false}}
log_message = "X-W-HS Host $sender_host_address banned - too many ($acl_m309) mail for not exists users!"
accept
Дык всё вроде хорошо - пашет - но проскакивает такое дело: в БД попадают ип-шники из внутренней сети (юзеры) - такое ощущение что не срабатывает hosts = !+relay_from_hosts - как лечить, куда пнуть?
Система: Linux Slackware 12.1 - Exim 4.69 + MySql Ver 14.12 Distrib 5.0.51b