This article provides a guide for how to configure a zone template so newly added domains get a DMARC record. This guide assumes you have root-equivalent access to cPanel VPS or cPanel dedicated server.
Introduction
You may use the following procedure to ensure that newly created accounts and domains get a basic DMARC record by default.
Configure a Zone Template So Newly Added Domains Get a DMARC Record
- Login to WHM as the root user.
- Navigate to: "Home » DNS Functions » Edit Zone Templates".
- Click on the "Standard" template.
- Review the following example DMARC record, customize it to your needs, and then add it to the bottom of the template:
_dmarc IN TXT v=DMARC1\;p=quarantine\;sp=none\;adkim=r\;aspf=r\;pct=100\;fo=0\;rf=afrf\;ri=86400\;rua=mailto:dmarc\@%domain%\;ruf=mailto:dmarc\@%domain%
- Click the blue "Save" button.
Whenever you create a new account or domain, it will have the above DMARC record added to it.
In order to receive DMARC aggregate and error reports, the domain owner must create an email account that matches the rua and ruf options included in the DMARC record that you just added to the template in step 4 above.
The basic DMARC record in the above example has the following settings:
- Policy: Quarantine
- Subdomain Policy: None
- DKIM Mode: Relaxed
- Percentage: 100
- Generate Failures When: All checks fail
- Report Format: AFRF
- Report Interval: 86400
- Send Aggregate Mail Reports To: dmarc@newlycreatedomainexample.tld
- Send Failure Reports To: dmarc@newlycreatedomainexample.tld
Conclusion
You now know how to configure a zone template so newly added domains get a DMARC record.