fix(dns): drop obsolete ADSP DNS record

ADSP (RFC 5617) has been historic since 2013.
Almost no major domain (gmail,icloud,outlook,gmx etc.)
publishes the record, so the record may single
out chatmail relays with a single DNS query.
This commit is contained in:
holger krekel
2026-11-25 10:29:33 +01:00
parent 61ebbab7f0
commit 52fadfbc8d
4 changed files with 7 additions and 5 deletions
+4 -2
View File
@@ -68,7 +68,6 @@ def get_filled_zone_file(remote_data):
"CAA",
f'0 issue "letsencrypt.org;accounturi={remote_data["acme_account_url"]}"',
)
append_record(f"_adsp._domainkey.{d}.", "TXT", '"dkim=discardable"')
append_record(f"_submission._tcp.{d}.", "SRV", f"0 1 587 {d}.")
append_record(f"_submissions._tcp.{d}.", "SRV", f"0 1 465 {d}.")
append_record(f"_imap._tcp.{d}.", "SRV", f"0 1 143 {d}.")
@@ -103,7 +102,10 @@ def check_full_zone(sshexec, remote_data, out, zonefile) -> int:
out("WARNING: these recommended DNS entries are not set:\n")
for line in recommended_diff:
out(line)
if adsp := remote_data.get("ADSP"):
out("WARNING: this obsolete DNS entry can be deleted:\n")
out(f"_adsp._domainkey.{remote_data['mail_domain']}. TXT {adsp}")
if not (recommended_diff or required_diff):
if not (recommended_diff or required_diff or adsp):
out.green("Great! All your DNS entries are verified and correct.")
return returncode
+1
View File
@@ -26,6 +26,7 @@ def perform_initial_checks(mail_domain, pre_command=""):
WWW = query_dns("CNAME", f"www.{mail_domain}")
res = dict(mail_domain=mail_domain, A=A, AAAA=AAAA, MTA_STS=MTA_STS, WWW=WWW)
res["ADSP"] = query_dns("TXT", f"_adsp._domainkey.{mail_domain}")
res["acme_account_url"] = shell(
pre_command + "acmetool account-url", fail_ok=True, print=log_progress
)
@@ -11,7 +11,6 @@ opendkim._domainkey.zftest.testrun.org. 3600 IN TXT "v=DKIM1;k=rsa;p=MIIB
zftest.testrun.org. 3600 IN TXT "v=spf1 a ~all"
_dmarc.zftest.testrun.org. 3600 IN TXT "v=DMARC1;p=reject;adkim=s;aspf=s"
zftest.testrun.org. 3600 IN CAA 0 issue "letsencrypt.org;accounturi=https://acme-v02.api.letsencrypt.org/acme/acct/1371472956"
_adsp._domainkey.zftest.testrun.org. 3600 IN TXT "dkim=discardable"
_submission._tcp.zftest.testrun.org. 3600 IN SRV 0 1 587 zftest.testrun.org.
_submissions._tcp.zftest.testrun.org. 3600 IN SRV 0 1 465 zftest.testrun.org.
_imap._tcp.zftest.testrun.org. 3600 IN SRV 0 1 143 zftest.testrun.org.
+2 -2
View File
@@ -207,7 +207,7 @@ class TestZonefileChecks:
parse_zonefile_into_dict(zonefile_mocked, mockdns_base)
required_diff, recommended_diff = remote.rdns.check_zonefile(zonefile)
assert not required_diff
assert len(recommended_diff) == 8
assert len(recommended_diff) == 7
def test_check_zonefile_output_required_fine(self, cm_data, mockdns_base, mockout):
zonefile = cm_data.get("zftest.zone")
@@ -218,7 +218,7 @@ class TestZonefileChecks:
res = check_full_zone(mssh, mockdns_base, out=mockout, zonefile=zonefile)
assert res == 0
assert "WARNING" in mockout.captured_plain[0]
assert len(mockout.captured_plain) == 9
assert len(mockout.captured_plain) == 8
def test_check_zonefile_output_full(self, cm_data, mockdns_base, mockout):
zonefile = cm_data.get("zftest.zone")