首页
学习
活动
专区
圈层
工具
发布
社区首页 >问答首页 >如何正确设置DNS SPF记录?

问如何正确设置DNS SPF记录?
EN

Stack Overflow用户
提问于 2012-03-20 09:45:39
回答 1查看 60.8K关注 0票数 30

我每周向订阅者发送电子邮件,结果发现邮件经常会发送给用户的垃圾邮件文件夹。

我正在利用Amazon发送这些消息,并按照他们的说明添加了一个SPF记录:http://docs.amazonwebservices.com/ses/latest/DeveloperGuide/SPFSenderIDDKIM.html?r=3917

在查询我的域的SPF记录时,我从http://www.kitterman.com/spf/validate.html获得以下信息

代码语言:javascript
复制
SPF record lookup and validation for: mydomain.tld

SPF records are primarily published in DNS as TXT records.

The TXT records found for your domain are:


SPF records should also be published in DNS as type SPF records.
Type SPF records found for the domain are:


Checking to see if there is a valid SPF record. 

Found v=spf1 record for mydomain.tld: 
v=spf1 include:amazonses.com ?all 

evaluating...
Results - record processed without error.

The result of the test (this should be the default result of your record) was, none . The explanation returned was,

对于我的CloudFlare DNS记录,我有:

代码语言:javascript
复制
SPF  mydomain.tld   v=spf1 include:amazonses.com ?all   with automatic TTL
TXT  mydomain.tld   spf2.0/pra include:amazonses.com ?all   with automatic TTL

这些电子邮件是从“no-回@mydomain.tld”和"admin@mydomain.tld“发送的。

一些用户报告看到了以下消息:“虚假显示为”弹出消息“响应的消息(一种系统生成的电子邮件,在发送无法传递的消息(例如发送到无效电子邮件地址的消息)后可能会自动收到)。

用我目前的发送解决方案,我无法在电子邮件中添加一个DKIM。

如何解决这一问题,从而为我们的用户解决任何类型的收据问题?

EN

回答 1

Stack Overflow用户

回答已采纳

发布于 2012-03-20 10:23:05

您的域没有有效的TXT记录(请注意,测试没有返回任何记录,请参阅下面的工作示例),这是由于您定义的TXT记录周围缺少引号造成的,如支持的记录类型中所解释的

与大多数其他记录类型不同的是,对于TXT记录,数据字段基本上是自由的,甚至可能包括空格。请注意:当输入包含空格(如SPF记录)的字符串时,必须将字符串括在双引号中;否则,单个单词将被单独引用,并将记录分成多个部分。

下面是我们目前根据TXT成功地为亚马逊SES使用的验证您的电子邮件地址记录(确实很不幸,它们的文档没有满足引用需求):

代码语言:javascript
复制
"v=spf1 include:amazonses.com ~all"
"spf2.0/pra include:amazonses.com ~all"

因此,以下是您一直在运行的测试的简短结果:

代码语言:javascript
复制
SPF record lookup and validation for: [...]

SPF records are primarily published in DNS as TXT records.

The TXT records found for your domain are:
spf2.0/pra include:amazonses.com ~all 
v=spf1 include:amazonses.com ~all 

[...]

Checking to see if there is a valid SPF record. 

Found v=spf1 record for services.marescom.net: 
v=spf1 include:amazonses.com ~all 
票数 26
EN
页面原文内容由Stack Overflow提供。腾讯云小微IT领域专用引擎提供翻译支持
原文链接:

https://stackoverflow.com/questions/9784415

复制
相关文章

相似问题

领券
问题归档专栏文章快讯文章归档关键词归档开发者手册归档开发者手册 Section 归档