]> git.ipfire.org Git - dbl.git/commitdiff
checker: Don't follow CNAMEs any more
authorMichael Tremer <michael.tremer@ipfire.org>
Thu, 8 Jan 2026 11:04:37 +0000 (11:04 +0000)
committerMichael Tremer <michael.tremer@ipfire.org>
Thu, 8 Jan 2026 11:04:37 +0000 (11:04 +0000)
If we get a CNAME response, the domain exists. Maybe the target does
not, but that could change at any time.

Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
src/dnsbl/checker.py

index 8bb8df2993dba42c85ca8a205b9e04091ff7d95b..fb2e475fc81ac17e313b4551d24dcd0f2da62c94 100644 (file)
@@ -172,17 +172,6 @@ class Checker(object):
 
                # The response did not contain an answer to our question
                except dns.resolver.NoAnswer as e:
-                       response = e.response()
-
-                       if response:
-                               # If we have received a CNAME, we will resolve again
-                               for rrset in response.answer:
-                                       if rrset.rdtype == dns.rdatatype.CNAME:
-                                               for record in rrset:
-                                                       hostname = record.target.to_text(omit_final_dot=True)
-
-                                                       return self.submit(domain, hostname=hostname)
-
                        # If we have received no response, that does mean that we might not
                        # have found the root of the domain, but something at least responded.
                        status = True