The DNS overview "Download" produces a $ORIGIN zonefile, but the
right-hand side of MX, CNAME and SRV records was emitted as a relative
name. A target such as mail.example.net is then read relative to the
origin and expands to mail.example.net.example.org., which is wrong.
The only prior attempt at making names absolute was
str_replace($domain, $domain . '.', ...), which appended a dot only to
targets that happened to contain the origin domain, so cross-domain
targets stayed relative. That same replace also corrupted any TXT value
containing the origin (e.g. a DMARC rua=mailto:x@example.org became
...@example.org.).
Absolutize the RHS per record type at export time only: MX and CNAME
targets, and the SRV target token, get a trailing dot; ports, the SRV
root target ".", IP addresses and TXT character strings are left as is.
The records used for the on-page DNS validation are untouched, so
matching against dns_get_record() output still works.
Fixes#6984
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
* Initial plan
* Add MTA-STS support for alias domains
Co-authored-by: DerLinkman <62480600+DerLinkman@users.noreply.github.com>
* Improve domain normalization and code style in mta-sts.php
Co-authored-by: DerLinkman <62480600+DerLinkman@users.noreply.github.com>
* Add error handling for idn_to_ascii in mta-sts.php
Co-authored-by: DerLinkman <62480600+DerLinkman@users.noreply.github.com>
* Add database error handling for alias domain query
Co-authored-by: DerLinkman <62480600+DerLinkman@users.noreply.github.com>
* Add ACME certificate support for MTA-STS on alias domains
Query alias_domain table to find aliases with MTA-STS enabled target domains and request certificates for mta-sts.<alias-domain> subdomains.
Co-authored-by: DerLinkman <62480600+DerLinkman@users.noreply.github.com>
* compose: bump image tag to 1.95
* Add MTA-STS DNS records display for alias domains in UI
When viewing an alias domain's DNS diagnostics, check if the target domain has MTA-STS enabled and display the required DNS records for the alias domain.
Co-authored-by: DerLinkman <62480600+DerLinkman@users.noreply.github.com>
---------
Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>
Co-authored-by: DerLinkman <62480600+DerLinkman@users.noreply.github.com>
Co-authored-by: DerLinkman <niklas.meyer@servercow.de>