postal icon indicating copy to clipboard operation
postal copied to clipboard

SPF Record Validation Problem.

Open mjml1982 opened this issue 6 years ago • 7 comments

Hi,

I have added domain postal.mydomain.com in the configuration file, the SPF record which postal suggest in the domain configuration is given below, so when I add record like this in the DNS of the domain Postal verifies the record but when i send email different ISP's like Gmail, outlook and mail-tester.com fails the SPF record. v=spf1 a mx include:spf.postal.mydomain.com ~all

When I add SPF record including the IP address of the server, Postal fails the verification but ISP's verifies the record not sure what's going on.

Could you please help how I can add correct SPF record for my domain.

v=spf1 a mx ip4:xxx.xxx.xxx.xxx ~all

Thanks.

mjml1982 avatar Aug 25 '20 17:08 mjml1982

You need to add SPF record for the subdomain spf.postal.mydomain.com such that it includes your Postal IPs.

Then add another SPF record for your sending domain to include "spf.postal.mydomain.com".

yomiit avatar Aug 26 '20 13:08 yomiit

Still having the same issue, this is what mail-tester shows.

Firefox_Screenshot_2020-08-26T14-19-51 730Z

mjml1982 avatar Aug 26 '20 14:08 mjml1982

My understanding based on screenshot suggests your psrp.yourdomain.com does not have SPF record. The psrp.yourdomain.com should be a CNAME to rp.postal.yourdomain.com. You should add Postal IPs to SPF record of rp.postal.yourdomain.com.

See Return Path section on the DNS configuration wiki

yomiit avatar Aug 26 '20 21:08 yomiit

That worked for me :) Thanks so much!

mjml1982 avatar Aug 27 '20 11:08 mjml1982

Great. Glad to hear.

yomiit avatar Aug 27 '20 17:08 yomiit

Hi I have an issue related to this.

I have a server with 2 IP addresses, x.x.x.1 and x.x.x.2

.yml file is updated with Return Path as rp.mail.service-provider.com

On IP-1, I have setup a Client-1.com, which is tested OK by postal and is doing fine.

On IP-2, there is Client-2.com. Also tested OK by postal but gmail etc. mark it as spam due to SPF error.

SPF: | PERMERROR with IP x.x.x.2 spf=permerror (google.com: permanent error in processing during lookup of [email protected]: mail.service-provider.com not found) client-ip=x.x.x.2 ;

It seems my YML file has RP set with IP-1, and gmail finds client-2.com coming from IP-2

I am totally confused. Please help. A sample running file from someone will be helpful.

Rgds...

JaiBansal24 avatar Sep 07 '20 05:09 JaiBansal24

It's difficult to troubleshoot this way. If you can share your domain and it's SPF output. Also, you can share your config too. Mask out important info you don't want to be public.

Use dig, nslookup, host or site like mxtoolbox [dot] com

yomiit avatar Sep 21 '20 23:09 yomiit