之前郵件伺服器全系列中漏發了Postgrey
系統使用CentOS 5.1 郵件伺服器全系列:Postfix+Dovecot+SASL+Procmail+Postgrey+Mailscanner+Spamassassin+ClamAV+Mailscanner-mrtg+MailWatch+Openwebmail+MySPAM
Postgrey就是所謂的灰名單功能,利用垃圾郵件主機大多是"射後不理"的特性,拒絕第一次的連線,待正常郵件伺服器進行再嘗試時,才允許連線並加入白名單。 1.安裝Postgrey yum install postgrey
2.啟動 postgrey service postgrey start chkconfig postgrey on
3.設定 postgrey for postfix 第一種設定方式 vim /etc/postfix/main.cf
smtpd_recipient_restrictions = permit_mynetworks, check_policy_service unix:/var/spool/postfix/postgrey/socket, reject_unauth_destination
第二種設定方式 a.vim /etc/sysconfig/postgrey
OPTIONS="--inet=127.0.0.1:10023 --delay=60"
b.vim /etc/postfix/main.cf
smtpd_recipient_restrictions = permit_mynetworks check_policy_service inet:127.0.0.1:10023 reject_unauth_destination
備註: ◎白名單 vim /etc/postfix/postgrey_whitelist_clients
vim /etc/postfix/postgrey_whitelist_recipients
◎清除記錄 vim /etc/postfix/postgrey_whitelist_recipients
rm /var/spool/postfix/postgrey/*