使用Spamassassin扫描即将离任的Postfix邮件

有没有办法用Spamassassin过滤垃圾邮件的垃圾邮件?

我发现这个答案是关于如何与Amavis做到的,但是这是非常过时的。

如果你结合起来

smtpd_sender_restrictions = check_client_access cidr:/etc/postfix/internal_clients_filter 

从您find的答案中find了clamsmtp传入过滤的说明 (不包括content_filter参数,并replace:

 192.168.0.0/24 FILTER smtp:[127.0.0.1]:12501 

 192.168.0.0/24 FILTER scan:[127.0.0.1]:10025 

用CIDR表示法中的networking地址replace192.168.0.0/24

别忘了

编辑/etc/clamsmtpd.conf文件并将OutAddress:10025更改为OutAddress:10026.也更改Listen:127.0.0.1:10026 Listen:127.0.0.1:10025

要么

将以下内容添加到/etc/postfix/master.cf

 # AV scan filter (used by content_filter) scan unix - - n - 16 smtp -o smtp_send_xforward_command=yes # For injecting mail back into postfix from the filter 127.0.0.1:10026 inet n - n - 16 smtpd -o content_filter= -o receive_override_options=no_unknown_recipient_checks,no_header_body_checks -o smtpd_helo_restrictions= -o smtpd_client_restrictions= -o smtpd_sender_restrictions= -o smtpd_recipient_restrictions=permit_mynetworks,reject -o mynetworks_style=host -o smtpd_authorized_xforward_hosts=127.0.0.0/8 

根据文章。

对不起,如果这是混乱。