Solved

spf record

Posted on 2016-10-26
8
107 Views
Last Modified: 2016-10-27
I have a client who has a domain name registered with their registrant,
  1. has their own on-prem exchange server
  2. and a website hosted by a 3rd party.  
  3. The website also creates emails when someone makes an online inquiry/feedback.

Today I tried to get the SPF record edited by the registrant, to include the website hosting providers domain and had what equates to an argument via chat over what is/isn't possible.  So I'm here in the court of Experts Exchange to see what your thoughts are.  

Exchange gateway address = 222.222.222.222 (just an example and sorry if its your IP)
Current spf = v=spf1 ip4:222.222.222.222 -all
Website hosting provider = worldsecuresystems.com (their real domain name)

Questions: (and some i know the answer but am starting as if I know nothing in case I am wrong)
  1. Is it possible to add a 2nd mail server to the SPF record?
  2. Can you have a mix of IP's and FQDN's in an spf record
  3. Is the spf syntax v=spf1 ip4:222.222.222.222 Include:worldsecuresystems.com -All
.

Reading resources on Googles own SPF reference talks about this exact scenario, yet openspf.org doesn't (or I haven't yet found)
0
Comment
Question by:mbkitmgr
8 Comments
 
LVL 5

Assisted Solution

by:Austin Texas
Austin Texas earned 83 total points
ID: 41861645
I think this is the authoritative document: https://support.google.com/a/answer/4568483?hl=en

add the mail server's IP address before the ~all argument using the format ip4:address or ip6:address to add the server to your existing SPF record:

v=spf1 ip4:83.206.106.17 include:_spf.google.com ~all
0
 
LVL 5

Author Comment

by:mbkitmgr
ID: 41861651
Thanks Austin, is the _spf part of the FQDN or is it Dmain Name syntax saying look for the spf for google.com?
0
 
LVL 16

Assisted Solution

by:Ivan
Ivan earned 83 total points
ID: 41861722
Hi,

as you wrote, it is possible to create SPF record of that type.
Question is, why are you making that modification?

When someone makes online inquiry, is mail going to be directed to exchange or is it sent to some other mail server? If it is sent to exchange, then you should create additional receive connector, that is going to accept connection from that provider and problem solved. Or if mail is send via some account, that is authenticated, then there should be no need to do anything. Just point to exchange.

You need SPF to help other mail servers identify if mail sent to them, sent from your mail servers. If you are sending mail to your exchange, from website, then you don't need to modify it.

Regards,
Ivan.
0
Best Practices: Disaster Recovery Testing

Besides backup, any IT division should have a disaster recovery plan. You will find a few tips below relating to the development of such a plan and to what issues one should pay special attention in the course of backup planning.

 
LVL 17

Assisted Solution

by:Malmensa
Malmensa earned 83 total points
ID: 41861787
1. Yes, large number of mail servers an be included in an SPF record.

2. Kinda, the FQDNs need to be prefixed with an INCLUDE mechanism, and if the domain references has no SPF record, it will break things. (always return a PERMERROR)

3. Yes, the syntax looks valid.
0
 
LVL 14

Accepted Solution

by:
Jason Crawford earned 251 total points
ID: 41861872
Your SPF record has a 256 character limit, and the current value belowonly uses 32 characters so you're good for now:

v=spf1 ip4:222.222.222.222 -all

You need to work with the web host and gather all WAN IPs they will use to send email on your behalf.  This can include a CIDR range, ie 222.222.222.0/24.  Your SPF record can also include recursive records which you demonstrated in your initial post with:

v=spf1 ip4:222.222.222.222 Include:worldsecuresystems.com -All

A great resource I've used for years to validate and test SPF records before publishing to DNS is Kitterman - http://www.kitterman.com/spf/validate.html.

One last thing.  If you do ever get yourself into a situation where you're approaching the 256 character limit, just nest an SPF record inside your SPF record.  Check out the SPF record for microsoft.com:

PS C:\Users\v-jacraw> Resolve-DnsName -Name microsoft.com -Type txt -Server 8.8.8.8

Name                                     Type   TTL   Section    Strings
----                                     ----   ---   -------    -------
microsoft.com                            TXT    2359  Answer     {docusign=d5a3737c-c23c-4bd0-9095-d2ff621
                                                                 f2840}
microsoft.com                            TXT    2359  Answer     {FbUF6DbkE+Aw1/wi9xgDi8KVrIIZus5v8L6tbIQZ
                                                                 kGrQ/rVQKJi8CjQbBtWtE64ey4NJJwj5J65PIggVY
                                                                 NabdQ==}
microsoft.com                            TXT    2359  Answer     {v=spf1 include:_spf-a.microsoft.com
                                                                 include:_spf-b.microsoft.com
                                                                 include:_spf-c.microsoft.com
                                                                 include:_spf-ssg-a.microsoft.com
                                                                 include:spf-a.hotmail.com
                                                                 ip4:147.243.128.24 ip4:147.243.128.26
                                                                 ip4:147.243.1.153 ip4:147.243.1.47
                                                                 ip4:147.243.1.48 -all}

Open in new window


You see how they nested '_spf-a.microsoft.com' inside the record?  If you query TXT record for _spf-a.microsoft.com you'll find the actual WAN IPs plus a few more nested records most likely.
0
 
LVL 5

Assisted Solution

by:Austin Texas
Austin Texas earned 83 total points
ID: 41862475
@mgkitmgr -

Sorry for the slow response...I fell asleep.

Yes, it is a FQDN. Another example:
"v=spf1 include:outlook.microsoft.com -all"
0
 
LVL 5

Author Comment

by:mbkitmgr
ID: 41863143
These are excellent responses from you all.

I tried the kitterman spf test with the correct IP address and syntax and it passes

 v=spf1 ip4:203.45.234.155 include:worldsecuresystems.com -all

As an FYI about the config, some other factors
  • The client does use a cloud spam filtering service which is looking for spf's to refine the filtering accuracy
  • The website developer tells me he cant modify any of the config of the website feedback/inquiry mechanism (not sure how factual this is - not my forte) except the recipient email address for the email it generates
  • He cant point the emails generated by feedback/inquiry at the IP or FQDN for the domain, making it important that we get the spf correct to ensure the emails get thru the filter and not treated as spoofed.
0
 
LVL 5

Author Closing Comment

by:mbkitmgr
ID: 41863145
The power of experts exchange.  Many many thanks.
0

Featured Post

What is SQL Server and how does it work?

The purpose of this paper is to provide you background on SQL Server. It’s your self-study guide for learning fundamentals. It includes both the history of SQL and its technical basics. Concepts and definitions will form the solid foundation of your future DBA expertise.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Read this checklist to learn more about the 15 things you should never include in an email signature.
This article explains how to install and use the NTBackup utility that comes with Windows Server.
In this video we show how to create a Shared Mailbox in Exchange 2013. We show this process by using the Exchange Admin Center. Log into Exchange Admin Center.: First we need to log into the Exchange Admin Center. Navigate to the Recipients >> Sha…
In this video we show how to create an Address List in Exchange 2013. We show this process by using the Exchange Admin Center. Log into Exchange Admin Center.: First we need to log into the Exchange Admin Center. Navigate to the Organization >> Ad…

777 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question