子域名的 SPF 记录对父域名有效吗?

子域名的 SPF 记录对父域名有效吗?

我曾经认为子域的 SPF 记录与父域完全独立。

我正在尝试一个域名电子邮件服务提供商,它建议:

使用子域名,您仍然可以从根域名发送电子邮件,例如“[电子邮件保护]”。

因此,我为特定子域名设置了 SPF,如下所示v=spf1 include:mailgun.org ~all

我尝试用它向知名的网络邮件提供商发送测试消息,令我惊讶的是,SPF 通过了。

Here are the relevant email headers:

Delivered-To: [email protected]
Return-Path: <[email protected]>
Received: from rs224.mailgun.us (rs224.mailgun.us. [209.61.151.224])
        by mx.google.com {...}
Received-SPF: pass (google.com: domain of [email protected] designates 209.61.151.224 as permitted sender) client-ip=209.61.151.224;
Sender: [email protected]
From: [email protected]
To: [email protected]

Received-SPF句话让我担心,出于某些扭曲的原因,SPF 仅基于退回地址的域名就能成功 - 是这样吗?

我还注意到,这Sender实际上是从子域设置的,但在网页邮件界面上却没有显示出来——这是否意味着子域基本上可以冒充父域的电子邮件?或者甚至其他域名?

答案1

SPF 是基于mail from电子邮件识别阶段的语法。

ehlo mail.example.com
mail from:[email protected]
rcpt to:[email protected]
data
Subject:This is the Subject
From:[email protected]
body Content

因此电子邮件可能是FROM您的域名,但 spf 基于mail from语法。

通常你会看到“代表[电子邮件保护]对于这种方法,有些需要Sender:example.com添加到这些电子邮件中,请参阅:发送方和返回路径之间的区别是什么

如果您包含实际域,我们可以提供更准确的信息。

相关内容