Since 2-3 weeks ago I'm getting errors and I cannot send email message from my server to Google / Gmail (Google must have changed something). I can send emails to other servers without issues. My hostname -fs is "moon.mydomain.com". I followed this tutorial to setup DKIM https://www.howtoforge.com/ispconfig-email-account/#dkim-email-signing-optional I have PTR record set years ago. gmail-smtp-in.l.google.com[2607:f8b0:4023:140d::1a] said: 550-5.7.26 Your email has been blocked because the sender is unauthenticated. 550-5.7.26 Gmail requires all senders to authenticate with either SPF or DKIM. 550-5.7.26 550-5.7.26 Authentication results: 550-5.7.26 DKIM = did not pass 550-5.7.26 SPF [mydomain.com] with ip: [b5ff:fe45:4a 550-5.7.26 97] = did not pass 550-5.7.26 550-5.7.26 For instructions on setting up authentication, go to 550 5.7.26 https://support.google.com/mail/answer/81126#authentication a1bbsi1241522385a.153 - gsmtp (in reply to end of DATA command) Reporting-MTA: dns; moon.mydomain.com Google Postmaster Tools (https://postmaster.google.com/v2/sender_compliance) SPF and DKIM authentication Needs work — Set up both SPF and DKIM authentication SPF prevents spammers from sending unauthorized messages that appear to be from your domain. Receiving servers use DKIM to verify that the domain owner actually sent the message. DNS records Needs work — Set up forward and reverse DNS records for domain Your sending IP address must have a PTR record. The hostname specified in the PTR record must have a forward DNS that refers to the sending IP address.
Have you set a PTR for the exact mentioned IPv6 address too, and not just IPv4? Also did you set thet IPv6 address in your SPF record?
Thank You @till / @remkoh. I just added IPv6 to PTR when I do a test for IPv4 & IPv6, my hostname is returned. I also added IPv6 to SPF in this format to DNS: v=spf1 mx ip4:xxx.xx.38.252 ip6:xxxx:xxxx:1000:1310:xxxx:b5ff:fe45:4a88 ~all I'm not sure why DKIM isn't published, I followed tutorial on DKIM. How do I make sure DKIM is published? Thank you in advance!
For example https://mxtoolbox.com/dkim.aspx checks that. There are other similar tools available, use Internet Search Engines with "dkim test tools". My signature has link to oldish tutorial on e-mail setup with ISPConfig.
That check is in the screenshots and says no record is published. Though it could be he has done the check wrong. If dns for the domain is managed by the same ispconfig than the txt-record should have been added automatically. If dns is hosted externally you have to publish the txt-record yourself using the data provided by ispconfig.
DNS is managed by the same ISPConfig server. I'm not sure why checks are failing. I enabled DKIM under EMAIL for the domain, TXT entry in DNS gets automatically added.
Are you sure you tested correctly at mxtoolbox? I always use mail-tester.com to test mailflow, dkim, spf, ptr etc. when I changed settings in or added a new maildomain. Almost always scoring 10/10.
@remkoh thank you. I tested with mail-tester.com shows score 10/10, for some odd reason MXToolbox still shows No DKIM Record found. I am able to send emails from my server to gmail without any issues. I no longer see "Your email has been blocked because the sender is unauthenticated. 550-5.7.26"
Keep in mind that mail-tester.com only tests ipv4. But now you know that dkim and everything ipv4 related is in order. Though ipv6 should be fine too since you added the ipv6 ptr record and added your ipv6 address to the spf record.