diff --git a/ChangeLog b/ChangeLog index 1e049fb..10f29b1 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,7 @@ +Version 1.0.1 + - Follow CNAMES when looking up key records when using DNS (pydns) + (LP: #1856421) + 2019-12-09 Version 1.0.0 - Add support for RFC 8460 tlsrpt DKIM signature processing (LP: #1847020) - Add async support with aiodns for DKIM verification (ARC not supported) diff --git a/dkim/dnsplug.py b/dkim/dnsplug.py index eab4add..1a2e12c 100644 --- a/dkim/dnsplug.py +++ b/dkim/dnsplug.py @@ -44,7 +44,10 @@ def get_txt_pydns(name, timeout=5): response = DNS.DnsRequest(name, qtype='txt', timeout=timeout).req() if not response.answers: return None - return b''.join(response.answers[0]['data']) + for answer in response.answers: + if answer['typename'].lower() == 'txt': + return b''.join(answer['data']) + return None # No longer used since it doesn't support timeout