我在Ubuntu 12.0.4.4上运行exim4(4.76)。
exim4被设置为处理mydomain.com的邮件。 我设置了别名,将[email protected]转发给[email protected]。 我将SpamAssassin设置为与exim4(通过sa-exim.conf)结合使用。
有时,垃圾邮件会发送到[email protected],SpamAssassin会将其分配到足够低的分数,并将其转发给[email protected]。 GMail拒绝邮件作为垃圾邮件,所以我的exim4服务器试图发送邮件回垃圾邮件地址说:
This message was created automatically by mail delivery software. A message that you sent could not be delivered to one or more of its recipients. This is a permanent error. The following address(es) failed: [email protected] (generated from [email protected]) SMTP error from remote mail server after end of data: host gmail-smtp-in.l.google.com [2607:f8b0:4003:c02::1a]: 550-5.7.1 [xxxx:yyyy::zzzz:aaaa:bbbb:ccccc 12] Our system has detected that 550-5.7.1 this message is likely unsolicited mail. To reduce the amount of spam 550-5.7.1 sent to Gmail, this message has been blocked. Please visit 550-5.7.1 http://support.google.com/mail/bin/answer.py?hl=en&answer=188131 for 550 5.7.1 more information. c15si25934770obf.31 - gsmtp
我不希望这封电子邮件发送回垃圾邮件地址,因为它显示别名的目的地“[email protected]”。
我怎样才能从拒绝邮件中删除“[email protected]”,或者完全拒绝那封拒绝邮件?
我不会build议试图隐藏你的电子邮件结构。 如果中断,您可能会错过解决问题的适当信息。
这是谷歌阻止的消息,所以这个问题可能与您的服务器。 如果你的电子邮件结构没有做好(固定的IP地址,有效的rDNS,SPF,DKIM和可选的DMARClogging),那么Google可能会popup消息,因为它们来自你的服务器。
如果你的服务器configuration合理,而且你的这种反弹量很大,那么你的垃圾邮件过滤可能不是很有效。 改善垃圾邮件过滤。 我发现三种垃圾邮件拦截技术非常有效:
zen.spamhaus.org阻止列表。 spamassassin过滤电子邮件。 sa-exim与Exim的沉重构buildExim 。
#validation发件人主机的反向DNS查找。
#延迟并禁用失败时的stream水线。
警告
!verify = reverse_host_lookup
延迟= 20s
control = no_pipelining
如果要validation目标是否有效,可以使用标注。 但是,如果您这样做,Gmail可能会阻止您。 以下来自标准configuration的代码是收件人标注。
#使用calloutvalidationlocal_rcpt_callout中列出的收件人。
#这对转发MX主机(辅助MX或者
#邮件中心)收到大量垃圾邮件到不存在的域
#地址。 检查本地部件以进行远程中继的唯一方法
#域名是使用标注(添加/标注),但请阅读
在做这个之前#关于标注的文档。
拒绝
!acl = acl_local_deny_exceptions
recipients = $ {if exists exists(CONFDIR / local_rcpt_callout)\
{CONFDIR / local_rcpt_callout} \
{}}
!validation=收件人/标注
你不能从任何configuration设置改变这个; 它被硬编码到源代码中。 如果要更改退回消息的输出,则必须编辑src / deliver.c中的print_address_information()函数并重buildexim的本地副本。
如果你真的想到这个,那会给你留下一个令人困惑的信息:
This message was created automatically by mail delivery software. A message that you sent could not be delivered to one or more of its recipients. This is a permanent error. The following address(es) failed: [email protected]: SMTP error from remote mail server after end of data: host gmail-smtp-in.l.google.com [2607:f8b0:4003:c02::1a]: 550-5.7.1 [xxxx:yyyy::zzzz:aaaa:bbbb:ccccc 12] Our system has detected that 550-5.7.1 this message is likely unsolicited mail. To reduce the amount of spam 550-5.7.1 sent to Gmail, this message has been blocked. Please visit 550-5.7.1 http://support.google.com/mail/bin/answer.py?hl=en&answer=188131 for 550 5.7.1 more information. c15si25934770obf.31 - gsmtp
任何postmaster会问的第一个问题是“如果mydomain.com没有被谷歌托pipe,为什么从谷歌邮件服务器退回消息。 此外,当你试图隐藏这样的事情,这会让你看起来不诚实和业余。 不要隐藏你的身份。