[SOLVED] Unknown domain from sendgrid

hata_ph

Well-Known Member
Nov 13, 2019
870
191
48
44
Notice sendgrid use CNAME for their emails services, you will encounter receiving issue if you enable reject_unknown_sender_domain.

You might want to whitelite the unknown domain under Configuration -> Mail Proxy -> whitelist.

1591245968253.png

Code:
Jun 4 12:37:14 pmg postfix/smtpd[27059]: connect from o1.em.autodeskcommunications.com[50.31.54.242]
Jun 4 12:38:24 pmg postfix/smtpd[27059]: NOQUEUE: reject: RCPT from o1.em.autodeskcommunications.com[50.31.54.242]: 450 4.1.8 <bounces+1595434-73df-xxx=xxx.com@em7210.autodesk.com>: Sender address rejected: Domain not found; from=<bounces+1595434-73df-xxx=xxx.com@em7210.autodesk.com> to=<xxx@xxx.com> proto=ESMTP helo=<o1.em.autodeskcommunications.com>
Jun 4 12:38:24 pmg postfix/smtpd[27059]: lost connection after RCPT from o1.em.autodeskcommunications.com[50.31.54.242]
Jun 4 12:38:24 pmg postfix/smtpd[27059]: disconnect from o1.em.autodeskcommunications.com[50.31.54.242] ehlo=1 mail=1 rcpt=0/1 commands=2/3
 
Last edited:
This sounds odd- and should not be necessary - CNAME processing is something that works in SMTP-context.

I tried imposing as em7210.autodesk.com and it worked in my test-setup

maybe the domain was new and DNS-propagation still was not completely done?
 
Don't think it is related to DNS propagation issue. Until now I also facing the issue from sendgrid.

1591341037184.png

1591340863241.png

Code:
Jun  5 14:43:39 pmg postfix/smtpd[24991]: connect from o4.email.wetransfer.com[192.254.123.89]
Jun  5 14:44:49 pmg postfix/smtpd[24991]: NOQUEUE: reject: RCPT from o4.email.wetransfer.com[192.254.123.89]: 450 4.1.8 <bounces+922094-df3d-xxx=xxx.com@em9713.email.wetransfer.com>: Sender address rejected: Domain not found; from=<bounces+922094-df3d-xxx=xxx.com@em9713.email.wetransfer.com> to=<xxx@xxx.com> proto=ESMTP helo=<o4.email.wetransfer.com>
Jun  5 14:44:49 pmg postfix/smtpd[24991]: lost connection after RCPT from o4.email.wetransfer.com[192.254.123.89]
Jun  5 14:44:49 pmg postfix/smtpd[24991]: disconnect from o4.email.wetransfer.com[192.254.123.89] ehlo=1 mail=1 rcpt=0/1 commands=2/3
 
em9713.email.wetransfer.com has a CNAME to u922094.wl095.sengrid.net.
u922094.wl095.sengrid.net has no A record, but an MX record mx.sendgrid.net.

this is enough for the postfix check (I tried again with the option enabled and the constructed testmail did pass here)

check your DNS settings on your PMG

install ldnsutils and run the following:
Code:
drill any em9713.email.wetransfer.com
drill any u922094.wl095.sengrid.net
 
Here you go. My local DNS is 192.168.41.180.

Code:
root@pmg:~# drill any em9713.email.wetransfer.com
;; ->>HEADER<<- opcode: QUERY, rcode: NOERROR, id: 7637
;; flags: qr rd ra ; QUERY: 1, ANSWER: 1, AUTHORITY: 0, ADDITIONAL: 0
;; QUESTION SECTION:
;; em9713.email.wetransfer.com. IN      ANY

;; ANSWER SECTION:
em9713.email.wetransfer.com.    250     IN      CNAME   u922094.wl095.sendgrid.net.

;; AUTHORITY SECTION:

;; ADDITIONAL SECTION:

;; Query time: 8535 msec
;; SERVER: 192.168.41.180
;; WHEN: Fri Jun  5 18:09:04 2020
;; MSG SIZE  rcvd: 85
root@pmg:~#
root@pmg:~# drill any u922094.w1095.sendgrid.net
;; ->>HEADER<<- opcode: QUERY, rcode: NXDOMAIN, id: 41129
;; flags: qr rd ra ; QUERY: 1, ANSWER: 0, AUTHORITY: 1, ADDITIONAL: 0 
;; QUESTION SECTION:
;; u922094.w1095.sendgrid.net.  IN      ANY

;; ANSWER SECTION:

;; AUTHORITY SECTION:
sendgrid.net.   180     IN      SOA     ns10.dnsmadeeasy.com. dns.dnsmadeeasy.com. 2011185620 14400 600 1728000 180

;; ADDITIONAL SECTION:

;; Query time: 42 msec
;; SERVER: 192.168.41.180
;; WHEN: Fri Jun  5 18:11:05 2020
;; MSG SIZE  rcvd: 104
root@pmg:~#
 
seems this particular domain has a problem - I did get your result as well - but also -
Code:
drill any  em9713.email.wetransfer.com
;; ->>HEADER<<- opcode: QUERY, rcode: NOERROR, id: 18691
;; flags: qr rd ra ; QUERY: 1, ANSWER: 3, AUTHORITY: 0, ADDITIONAL: 0 
;; QUESTION SECTION:
;; em9713.email.wetransfer.com.    IN    ANY

;; ANSWER SECTION:
em9713.email.wetransfer.com.    63    IN    CNAME    u922094.wl095.sendgrid.net.
u922094.wl095.sendgrid.net.    1766    IN    TXT    "v=spf1 ip4:167.89.35.243 ip4:167.89.35.32 ip4:167.89.5.15 ip4:167.89.54.234 ip4:167.89.54.238 ip4:167.89.54.247 ip4:192.254.117.71 ip4:192.254.118.54 ip4:192.254.123.42 ip4:192.254.123.89 -all"
u922094.wl095.sendgrid.net.    1766    IN    MX    20 mx.sendgrid.net.

;; AUTHORITY SECTION:

;; ADDITIONAL SECTION:

;; Query time: 0 msec
;; SERVER: 192.168.2.15
;; WHEN: Fri Jun  5 13:18:49 2020
;; MSG SIZE  rcvd: 309

so it seems there is a problem with sendgrid's DNS setup (some authoritative server having the necessary MX record, another one not)

the smtp-whitelist works as a workaround - but you could also inform sendgrid about the issue.
 
Just to follow up, seem like sendgrid have fix their DNS issue. I no longer need to whitelist their subdomain any more.

Code:
root@pmg:~# drill any em9713.email.wetransfer.com
;; ->>HEADER<<- opcode: QUERY, rcode: NOERROR, id: 58041
;; flags: qr rd ra ; QUERY: 1, ANSWER: 1, AUTHORITY: 0, ADDITIONAL: 0
;; QUESTION SECTION:
;; em9713.email.wetransfer.com. IN      ANY

;; ANSWER SECTION:
em9713.email.wetransfer.com.    299     IN      CNAME   u922094.wl095.sendgrid.net.

;; AUTHORITY SECTION:

;; ADDITIONAL SECTION:

;; Query time: 243 msec
;; SERVER: 192.168.41.181
;; WHEN: Thu Jun 11 08:56:42 2020
;; MSG SIZE  rcvd: 85
root@pmg:~# drill any u922094.wl095.sengrid.net
;; ->>HEADER<<- opcode: QUERY, rcode: NOERROR, id: 9780
;; flags: qr rd ra ; QUERY: 1, ANSWER: 5, AUTHORITY: 0, ADDITIONAL: 2
;; QUESTION SECTION:
;; u922094.wl095.sengrid.net.   IN      ANY

;; ANSWER SECTION:
u922094.wl095.sengrid.net.      600     IN      A       104.247.81.130
u922094.wl095.sengrid.net.      3600    IN      NS      ns2.parkingcrew.net.
u922094.wl095.sengrid.net.      10800   IN      SOA     ns1.parkingcrew.net. hostmaster.u922094.wl095.sengrid.net. 1591837000 28800 7200 604800 86400
u922094.wl095.sengrid.net.      3600    IN      MX      5 mail.h-email.net.
u922094.wl095.sengrid.net.      3600    IN      TXT     "v=spf1 ip6:fd1b:212c:a5f9::/48 -all"

;; AUTHORITY SECTION:

;; ADDITIONAL SECTION:
ns2.parkingcrew.net.    3622    IN      A       13.248.158.159
ns2.parkingcrew.net.    3622    IN      A       76.223.21.9

;; Query time: 28 msec
;; SERVER: 192.168.41.181
;; WHEN: Thu Jun 11 08:56:57 2020
;; MSG SIZE  rcvd: 249
 
Glad to hear! - please mark the thread as 'SOLVED'
Thanks!
 

About

The Proxmox community has been around for many years and offers help and support for Proxmox VE, Proxmox Backup Server, and Proxmox Mail Gateway.
We think our community is one of the best thanks to people like you!

Get your subscription!

The Proxmox team works very hard to make sure you are running the best software and getting stable updates and security enhancements, as well as quick enterprise support. Tens of thousands of happy customers have a Proxmox subscription. Get yours easily in our online shop.

Buy now!