DKIM / DMARC not working.
I am very new to everything about domains and such things, so I will try to explain my problem as best as I can:
I followed this guide in order to make mails outgoing from my VPS less of a threat to the outside world, but the DKIM/DMARC configuration didn't seem to work. I have a TXT name:
mail._domainkey.mydomain.com and the text value:
v=DKIM1; k=rsa; p=keystring
However, in the DO Control Panel, in the "Zone file" area, I'm shown this:
mail._domainkey.mydomain.com.mydomain.com. 1800 IN TXT v=DKIM1; k=rsa; p=keystring
I'm not sure it should be using the domain name twice, so I changed the TXT name to simply:
And that fixed the "Zone file" repetition. However, this website hasn't been able to validate the DKIM key in any of the two aforementioned ways, and always gives me the following error:
This is not a good DKIM key record. You should fix the errors shown in red.
DNS query failed for 'mail._domainkey.mydomain.com':NXDOMAIN
A public-key (p=) is required
What am I doing wrong, and how can I fix it?
As a side note, "mydomain.com is just an alias I used to keep my actual domani hidden. Additionally, I don't have any ports open other than a custom port for OpenVPN and another custom port for nginx, in case it needs an open port.
If you need more info, I will gladly provide it.