Add DMARC to all domains except existing records and external MX

Richard G

Verified User
Joined
Jul 6, 2008
Messages
13,771
Location
Maastricht
It seems that both Google and Yahoo now require a DMARC record by default for mass mailing by februari 2024 (>5000 mails).

Now our customers do not use mass mailing as far as I now, but it's better to be prepared, than to run behind the facts.
So jus to be sure I want to add them everywhere -except- for domains which already have a DMARC record!

Now for new domains I can create a custom dns template called dns_txt.conf and add a DMARC line in there, shouldn't be that difficult.

However, I also need to add this DMARC record with only p=none (which is sufficient) to all existing domains, but except domains with external MX present and except domains which already have a DMARC record present. Because I most certainly wouldn't like to overwrite some users well setup DMARC settings.

I found some script to put in an A record, which I have used once for imap, which was not present anywhere in DNS. But there was no example in the docs as to how to do this with a DMARC record and exclude the ones that I want exclusion for.

But I'm no scripter and now I need a script or some way to fix this.

So how can I do this?
 
Back
Top