Jea*_*ean 9 email spam-prevention
来自我们服务的一些(但不是全部)电子邮件被 gmail 标记为网络钓鱼,被 hotmail 标记为垃圾邮件。
被标记为网络钓鱼的电子邮件是从部署在 EC2 虚拟机上的应用程序发送的,该应用程序使用亚马逊 SES 进行实际发送。该应用程序会发送其他没有被标记的电子邮件(我们目前有 4 种应用程序发送的电子邮件)。
我们还有一个用户使用托管在 OVH 上的 MS Exchange 帐户从该域发送电子邮件,这就是 spf 记录包含 ovh 条目的原因。
我们在域上配置了以下记录:
_amazonses.mydomain.com. 1799 IN TXT "JiAZ9E5gIc7VbPfMI4rYSBGZJeTe3lTF+eigtVUF1fg="
_amazonses.mydomain.com. 1799 IN TXT "vkSOtQqrtz2frIPg+6SeU7CmCenkTPjjvZdCQe/u0Qk="
_dmarc.mydomain.com. 299 IN TXT "v=DMARC1\;p=none\;rua=mailto:postmaster@mydomain.com"
2anucjune6cx5dfjwtpg5w7xi5bivkdi._domainkey.mydomain.com. 1799 IN CNAME 2anucjune6cx5dfjwtpg5w7xi5bivkdi.dkim.amazonses.com.
5m7pppm63mxlxz3w3al3juxlgwb4j67m._domainkey.mydomain.com. 1799 IN CNAME 5m7pppm63mxlxz3w3al3juxlgwb4j67m.dkim.amazonses.com.
7tpgaubzvve5ekkq3pyu7rhmrxhgif5f._domainkey.mydomain.com. 1799 IN CNAME 7tpgaubzvve5ekkq3pyu7rhmrxhgif5f.dkim.amazonses.com.
mydomain.com. 299 IN TXT "v=spf1 a mx include:amazonses.com include:mx.ovh.com ~all"
mydomain.com. 299 IN SPF "v=spf1 a mx include:amazonses.com include:mx.ovh.com ~all"
Run Code Online (Sandbox Code Playgroud)
以下是我们从谷歌获得的 DMARC 报告:
<record>
<row>
<source_ip>54.240.6.219</source_ip>
<count>1</count>
<policy_evaluated>
<disposition>none</disposition>
<dkim>pass</dkim>
<spf>fail</spf>
</policy_evaluated>
</row>
<identifiers>
<header_from>mydomain.com</header_from>
</identifiers>
<auth_results>
<dkim>
<domain>mydomain.com</domain>
<result>pass</result>
</dkim>
<spf>
<domain>eu-west-1.amazonses.com</domain>
<result>pass</result>
</spf>
</auth_results>
</record>
Run Code Online (Sandbox Code Playgroud)
这是来自 hotmail.com 的一个
<record>
<row>
<source_ip>54.240.6.212</source_ip>
<count>1</count>
<policy_evaluated>
<disposition>none</disposition>
<dkim>pass</dkim>
<spf>fail</spf>
</policy_evaluated>
</row>
<identifiers>
<header_from>mydomain.com</header_from>
</identifiers>
<auth_results>
<spf>
<domain>eu-west-1.amazonses.com</domain>
<result>pass</result>
</spf>
<dkim>
<domain>mydomain.com</domain>
<result>pass</result>
</dkim>
</auth_results>
Run Code Online (Sandbox Code Playgroud)
正如您所看到的,policy_evaluated 的 SPF 条目有一个fail状态,但是 auth_results 将 spf 列为 is pass。什么可以解释语无伦次的状态?这种不一致会导致我们的邮件被标记为网络钓鱼/垃圾邮件吗?
这似乎是由于 DMARC 域对齐问题。如报告所示,SPF认证结果的域为“eu-west-1.amazonses.com”,与“mydomain.com”的header_from不一致。为什么 DMARC 使用 amazonses.com 域进行 SPF 评估,我不知道。我有同样的问题,还没有弄清楚如何解决它。从DMARC 草案:
Example 3. This record indicates a single message matching this set
of data points. The DMARC disposition for this message was "reject"
based on DMARC aligned results for SPF and DKIM of "fail" and the
domain's reject policy. There was no DKIM signature on this message,
as in Example 1. The SPF authentication result was "pass" with a
MAILFROM domain of "classifiedads.com". The SPF domain is not
aligned with the header From domain, causing the DMARC aligned SPF
result to be "fail".
<record>
<row>
<source_ip>65.61.105.5</source_ip>
<count>1</count>
<policy_evaluated>
<disposition>reject</disposition>
<dkim>fail</dkim>
<spf>fail</spf>
</policy_evaluated>
</row>
<identifiers>
<header_from>facebook.com</header_from>
</identifiers>
<auth_results>
<dkim>
<domain></domain>
<result>none</result>
</dkim>
<spf>
<domain>classifiedads.com</domain>
<result>pass</result>
</spf>
</auth_results>
</record>
Run Code Online (Sandbox Code Playgroud)
小智 6
这不太可能是您的邮件被标记为网络钓鱼/垃圾邮件的原因。您的 <policy_evaluated> 元素表明您正在通过 DKIM,因此您正在通过 DMARC 作为一个整体。
policy_evaluated 的 SPF 条目具有失败状态,但是 auth_results 将 spf 列为通过。什么可以解释语无伦次的状态?
auth_results 不考虑标识符对齐,而整体 DMARC 评估会考虑,这就是 SPF 的 auth_results 可以通过而整体 SPF 结果可以失败的原因。
为什么 SPF 是针对 amazonses.com 域而不是您的域进行评估的?与 DKIM 不同,SPF 不会验证 From 标头中的域名(这将是您的域)。它验证 SMTP 发件人的 IP 地址。在这种情况下,这是一个亚马逊 IP 地址,它正确地通过了 SPF。
参考:
https://tools.ietf.org/html/rfc7489
http://sesblog.amazon.com/post/Tx3IREZBQXXL8O8/SPF-and-Amazon-SES
| 归档时间: |
|
| 查看次数: |
6393 次 |
| 最近记录: |