將郵件伺服器換成 Postfix + pop-before-smtp *
故名思意,pop-before-smtp 就是在 smtp 前,先用 pop3 的帳號登入,以確保伺服器上有你的帳號。以下的步驟,先將 Sendmail 換成 Postfix,再將 smtp 的認証則改用 pop-before-smtp 的方式。
安裝 Postfix
apt-get remove sendmail
apt-get install postfix
myhostname -> host.example.com mydomain -> example.com myorigin -> $myhostname inet_interfaces -> all mydestination -> /etc/postfix/local-host-names mynetworks -> 127.0.0.0/8, hash:/etc/postfix/access relay_domains -> $mydestination alias_maps -> hash:/etc/postfix/aliases
example.com mail.example.com host.example.com
postmap hash:/etc/postfix/access postalias hash:/etc/postfix/aliases
service postfix start
安裝 pop-before-smtp
顧名思義,pop-before-smtp 就是在寄信前,必須先用 pop3 檢查郵件,只要 pop3 登入正確,你就可以用同一台伺服器寄信 (30分鐘內)。安裝步驟如下:
perl -MCPAN -e 'install File::Tail' perl -MCPAN -e 'install Time::HiRes' perl -MCPAN -e 'install Net::Netmask' perl -MCPAN -e 'install Date::Parse'
cd /tmp wget http://www.vixual.net/download/source/postfix/pop-before-smtp-1.33-1.noarch.rpm rpm -ivh pop-before-smtp-1.33-1.noarch.rpm
#$file_tail{'name'} = '/var/log/maillog'; #$grace = 30*60; #$dbfile = '/etc/postfix/pop-before-smtp';
smtpd_recipient_restrictions = permit_mynetworks,reject_non_fqdn_recipient,check_client_access hash:/etc/postfix/pop-before-smtp,check_relay_domains
service pop-before-smtp start service postfix reload
No comments yet.