Sendmail

sendmail 無法發送到 gmail - 未滿足有關 PTR 記錄的 IPv6 發送準則

  • August 11, 2021

我無法從 ubuntu 14.04 上的全新 sendmail 安裝向 google 發送郵件。DNS記錄似乎對ip沒問題。肯定有其他問題。

從命令行發送郵件:

sudo sendmail -v -Am -i myname@gmail.com;

詳細輸出:

myname@fx1:/etc/mail$ sudo sendmail -v -Am -i myname@gmail.com;
myname@gmail.com... Connecting to aspmx.l.google.com. via esmtp...
220 mx.google.com ESMTP v1si55415385wja.21 - gsmtp
>>> EHLO staging.mydomain.com
250-mx.google.com at your service, [2a01:4f8:212:27c8::2]
250-SIZE 35882577
250-8BITMIME
250-STARTTLS
250-ENHANCEDSTATUSCODES
250-PIPELINING
250-CHUNKING
250 SMTPUTF8
>>> STARTTLS
220 2.0.0 Ready to start TLS
>>> EHLO staging.mydomain.com
250-mx.google.com at your service, [2a01:4f8:212:27c8::2]
250-SIZE 35882577
250-8BITMIME
250-ENHANCEDSTATUSCODES
250-PIPELINING
250-CHUNKING
250 SMTPUTF8
>>> MAIL From:<myname@staging.mydomain.com>
250 2.1.0 OK v1si55415385wja.21 - gsmtp
>>> RCPT To:<myname@gmail.com>
>>> DATA
250 2.1.5 OK v1si55415385wja.21 - gsmtp
354  Go ahead v1si55415385wja.21 - gsmtp
>>> .
550-5.7.1 [2a01:4f8:212:27c8::2] Our system has detected that this message does
550-5.7.1 not meet IPv6 sending guidelines regarding PTR records and
550-5.7.1 authentication. Please review
550-5.7.1  https://support.google.com/mail/?p=ipv6_authentication_error for more
550 5.7.1 information. v1si55415385wja.21 - gsmtp
myname... Connecting to local...
myname... Sent

非常感謝任何幫助。先感謝您。

從 Google 的角度來看,他們正在嘗試驗證連接到他們的 IP 地址的身份,因此他們將嘗試PTR查找2a01:4f8:212:27c8::2.

當他們將其解析為時staging.findix.com,他們將嘗試檢查它是否解析回2a01:4f8:212:27c8::2- 它沒有 - 看到此查找結果

反向(PTR 記錄)查找

cwatson@thor:~$ nslookup 31.220.4.52
Server:     127.0.0.1
Address:    127.0.0.1#53

Non-authoritative answer:
52.4.220.31.in-addr.arpa    name = tyr.vikingserv.net.

正向(A 記錄)查找

cwatson@thor:~$ nslookup tyr.vikingserv.net
Server:     127.0.0.1
Address:    127.0.0.1#53

Non-authoritative answer:
Name:   tyr.vikingserv.net
Address: 31.220.4.52

引用自:https://serverfault.com/questions/732187