]> git.ipfire.org Git - thirdparty/systemd.git/commitdiff
resolved: use DNS_TYPE_DNSKEY for trust anchor support (#40850)
authorAnton Tiurin <atiurin@proton.me>
Mon, 2 Mar 2026 04:44:26 +0000 (04:44 +0000)
committerGitHub <noreply@github.com>
Mon, 2 Mar 2026 04:44:26 +0000 (13:44 +0900)
Fix typo: DNS_TYPE_DNSKEY should be used instead of DNS_TYPE_KEY.
- DNS_TYPE_KEY is deprecated
- Source code at resolved-dns-trust-anchor.c#L313 handles
DNS_TYPE_DNSKEY records, but not DNS_TYPE_KEY
So DNS_TYPE_KEY is not referenced anywhere

src/resolve/resolved-dns-trust-anchor.c

index 0896dc870c3742816ab83cfebb108cf402f7942c..f1ffee23b3f5fea69b4fbbcabe5081ee17ec31cc 100644 (file)
@@ -581,7 +581,7 @@ int dns_trust_anchor_lookup_negative(DnsTrustAnchor *d, const char *name) {
                 if (hashmap_contains(d->positive_by_key, &DNS_RESOURCE_KEY_CONST(DNS_CLASS_IN, DNS_TYPE_DS, name)))
                         return false;
 
-                if (hashmap_contains(d->positive_by_key, &DNS_RESOURCE_KEY_CONST(DNS_CLASS_IN, DNS_TYPE_KEY, name)))
+                if (hashmap_contains(d->positive_by_key, &DNS_RESOURCE_KEY_CONST(DNS_CLASS_IN, DNS_TYPE_DNSKEY, name)))
                         return false;
 
                 /* And now, let's look at the parent, and check that too */