Script 'mail_helper' called by obssrc Hello community, here is the log from the commit of package python-dnslib for openSUSE:Factory checked in at 2023-01-04 17:53:52 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Comparing /work/SRC/openSUSE:Factory/python-dnslib (Old) and /work/SRC/openSUSE:Factory/.python-dnslib.new.1563 (New) ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "python-dnslib" Wed Jan 4 17:53:52 2023 rev:6 rq:1055878 version:0.9.23 Changes: -------- --- /work/SRC/openSUSE:Factory/python-dnslib/python-dnslib.changes 2022-09-29 18:12:17.595130539 +0200 +++ /work/SRC/openSUSE:Factory/.python-dnslib.new.1563/python-dnslib.changes 2023-01-04 17:54:39.754910071 +0100 @@ -1,0 +2,14 @@ +Wed Jan 4 14:44:54 UTC 2023 - Dirk Müller <dmuel...@suse.com> + +- update to 0.9.23: + * Minor clean-up / add wheels to distro + * Issue #43 (0.9.21 Raises TypeError instead of DNSError when failing to parse HTTPS records) + Note that we just fix the exception - there still seems to be a problem with parsing HTTPS records + * Issue #43: HTTPS reads after RD end (thanks to @robinlandstrom for pull request) + * Issue #45: Dnslib fails to handle unknown RR types in NSEC RD type bitmap + * Bimap now supports a function to map unknown types which we use to + dynamically map from rtype <-> TYPExxxx for unknown record types + * RR zone representation updated to match RFC3597 + * Pull Request #47: Add support for DS, SSHFP, and TLSA records (thanks to @rmbolger) + +------------------------------------------------------------------- Old: ---- dnslib-0.9.20.tar.gz New: ---- dnslib-0.9.23.tar.gz ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Other differences: ------------------ ++++++ python-dnslib.spec ++++++ --- /var/tmp/diff_new_pack.CrjRDn/_old 2023-01-04 17:54:40.150912405 +0100 +++ /var/tmp/diff_new_pack.CrjRDn/_new 2023-01-04 17:54:40.154912428 +0100 @@ -1,7 +1,7 @@ # # spec file for package python-dnslib # -# Copyright (c) 2022 SUSE LLC +# Copyright (c) 2023 SUSE LLC # # All modifications and additions to the file contributed by third parties # remain the property of their copyright owners, unless otherwise agreed @@ -18,7 +18,7 @@ %{?!python_module:%define python_module() python-%{**} python3-%{**}} Name: python-dnslib -Version: 0.9.20 +Version: 0.9.23 Release: 0 Summary: Simple library to encode/decode DNS wire-format packets License: BSD-2-Clause ++++++ dnslib-0.9.20.tar.gz -> dnslib-0.9.23.tar.gz ++++++ diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/dnslib-0.9.20/PKG-INFO new/dnslib-0.9.23/PKG-INFO --- old/dnslib-0.9.20/PKG-INFO 2022-07-17 23:58:51.444941800 +0200 +++ new/dnslib-0.9.23/PKG-INFO 2022-10-28 19:28:52.501596500 +0200 @@ -1,6 +1,6 @@ Metadata-Version: 2.1 Name: dnslib -Version: 0.9.20 +Version: 0.9.23 Summary: Simple library to encode/decode DNS wire-format packets Home-page: https://github.com/paulc/dnslib Author: PaulC @@ -390,6 +390,16 @@ Fix display of non-printable characters in TXT records (Issue #32 - thanks to @sbv-csis) Add --strip-aaaa option to dnslib.proxy + * 0.9.21 2022-09-19 Minor clean-up / add wheels to distro + * 0.9.22 2022-09027 Issue #43 (0.9.21 Raises TypeError instead of DNSError when failing to parse HTTPS records) + Note that we just fix the exception - there still seems to be a problem with parsing HTTPS records + (Thanks to @robinlandstrom) + * 0.9.23 2022-10-28 Issue #43: HTTPS reads after RD end (thanks to @robinlandstrom for pull request) + Issue #45: Dnslib fails to handle unknown RR types in NSEC RD type bitmap + Bimap now supports a function to map unknown types which we use to + dynamically map from rtype <-> TYPExxxx for unknown record types + RR zone representation updated to match RFC3597 + Pull Request #47: Add support for DS, SSHFP, and TLSA records (thanks to @rmbolger) License: -------- diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/dnslib-0.9.20/README new/dnslib-0.9.23/README --- old/dnslib-0.9.20/README 2022-07-17 23:51:51.000000000 +0200 +++ new/dnslib-0.9.23/README 2022-10-28 19:25:14.000000000 +0200 @@ -377,6 +377,16 @@ Fix display of non-printable characters in TXT records (Issue #32 - thanks to @sbv-csis) Add --strip-aaaa option to dnslib.proxy + * 0.9.21 2022-09-19 Minor clean-up / add wheels to distro + * 0.9.22 2022-09027 Issue #43 (0.9.21 Raises TypeError instead of DNSError when failing to parse HTTPS records) + Note that we just fix the exception - there still seems to be a problem with parsing HTTPS records + (Thanks to @robinlandstrom) + * 0.9.23 2022-10-28 Issue #43: HTTPS reads after RD end (thanks to @robinlandstrom for pull request) + Issue #45: Dnslib fails to handle unknown RR types in NSEC RD type bitmap + Bimap now supports a function to map unknown types which we use to + dynamically map from rtype <-> TYPExxxx for unknown record types + RR zone representation updated to match RFC3597 + Pull Request #47: Add support for DS, SSHFP, and TLSA records (thanks to @rmbolger) License: -------- diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/dnslib-0.9.20/dnslib/__init__.py new/dnslib-0.9.23/dnslib/__init__.py --- old/dnslib-0.9.20/dnslib/__init__.py 2022-07-17 23:51:27.000000000 +0200 +++ new/dnslib-0.9.23/dnslib/__init__.py 2022-10-28 19:25:02.000000000 +0200 @@ -379,6 +379,16 @@ Fix display of non-printable characters in TXT records (Issue #32 - thanks to @sbv-csis) Add --strip-aaaa option to dnslib.proxy + * 0.9.21 2022-09-19 Minor clean-up / add wheels to distro + * 0.9.22 2022-09027 Issue #43 (0.9.21 Raises TypeError instead of DNSError when failing to parse HTTPS records) + Note that we just fix the exception - there still seems to be a problem with parsing HTTPS records + (Thanks to @robinlandstrom) + * 0.9.23 2022-10-28 Issue #43: HTTPS reads after RD end (thanks to @robinlandstrom for pull request) + Issue #45: Dnslib fails to handle unknown RR types in NSEC RD type bitmap + Bimap now supports a function to map unknown types which we use to + dynamically map from rtype <-> TYPExxxx for unknown record types + RR zone representation updated to match RFC3597 + Pull Request #47: Add support for DS, SSHFP, and TLSA records (thanks to @rmbolger) License: -------- @@ -401,7 +411,7 @@ from dnslib.dns import * -version = "0.9.20" +version = "0.9.23" if __name__ == '__main__': import doctest,sys,textwrap diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/dnslib-0.9.20/dnslib/bimap.py new/dnslib-0.9.23/dnslib/bimap.py --- old/dnslib-0.9.20/dnslib/bimap.py 2020-06-09 10:01:28.000000000 +0200 +++ new/dnslib-0.9.23/dnslib/bimap.py 2022-10-26 17:19:12.000000000 +0200 @@ -4,6 +4,8 @@ Bimap - bidirectional mapping between code/value """ +import sys,types + class BimapError(Exception): pass @@ -17,6 +19,8 @@ name: Used for exceptions dict: Dict mapping from code (numeric) to text error: Error type to raise if key not found + _or_ callable which either generates mapping + return error The class provides: @@ -47,6 +51,38 @@ >>> TEST.get(99) '99' + # Test with callable error + >>> def _error(name,key,forward): + ... if forward: + ... try: + ... return "TEST%d" % (key,) + ... except: + ... raise TestError("%s: Invalid forward lookup: [%s]" % (name,key)) + ... else: + ... if key.startswith("TEST"): + ... try: + ... return int(key[4:]) + ... except: + ... pass + ... raise TestError("%s: Invalid reverse lookup: [%s]" % (name,key)) + >>> TEST2 = Bimap('TEST2',{1:'A', 2:'B', 3:'C'},_error) + >>> TEST2[1] + 'A' + >>> TEST2[9999] + 'TEST9999' + >>> TEST2['abcd'] + Traceback (most recent call last): + ... + TestError: TEST2: Invalid forward lookup: [abcd] + >>> TEST2.A + 1 + >>> TEST2.TEST9999 + 9999 + >>> TEST2.X + Traceback (most recent call last): + ... + TestError: TEST2: Invalid reverse lookup: [X] + """ def __init__(self,name,forward,error=AttributeError): @@ -65,7 +101,10 @@ try: return self.forward[k] except KeyError as e: - raise self.error("%s: Invalid forward lookup: [%s]" % (self.name,k)) + if isinstance(self.error,types.FunctionType): + return self.error(self.name,k,True) + else: + raise self.error("%s: Invalid forward lookup: [%s]" % (self.name,k)) def __getattr__(self,k): try: @@ -74,7 +113,10 @@ raise AttributeError() return self.reverse[k] except KeyError as e: - raise self.error("%s: Invalid reverse lookup: [%s]" % (self.name,k)) + if isinstance(self.error,types.FunctionType): + return self.error(self.name,k,False) + else: + raise self.error("%s: Invalid reverse lookup: [%s]" % (self.name,k)) if __name__ == '__main__': import doctest,sys diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/dnslib-0.9.20/dnslib/dns.py new/dnslib-0.9.23/dnslib/dns.py --- old/dnslib-0.9.20/dnslib/dns.py 2022-07-17 23:49:03.000000000 +0200 +++ new/dnslib-0.9.23/dnslib/dns.py 2022-10-28 19:18:20.000000000 +0200 @@ -30,6 +30,20 @@ # DNS codes +def unknown_qtype(name,key,forward): + if forward: + try: + return "TYPE%d" % (key,) + except: + raise DNSError("%s: Invalid forward lookup: [%s]" % (name,key)) + else: + if key.startswith("TYPE"): + try: + return int(key[4:]) + except: + pass + raise DNSError("%s: Invalid reverse lookup: [%s]" % (name,key)) + QTYPE = Bimap('QTYPE', {1:'A', 2:'NS', 5:'CNAME', 6:'SOA', 10:'NULL', 12:'PTR', 13:'HINFO', 15:'MX', 16:'TXT', 17:'RP', 18:'AFSDB', 24:'SIG', 25:'KEY', @@ -41,7 +55,7 @@ 61:'OPENPGPKEY', 62:'CSYNC', 63:'ZONEMD', 64:'SVCB', 65:'HTTPS', 99:'SPF', 108:'EUI48', 109:'EUI64', 249:'TKEY', 250:'TSIG', 251:'IXFR', 252:'AXFR', 255:'ANY', 256:'URI', - 257:'CAA', 32768:'TA', 32769:'DLV'}, DNSError) + 257:'CAA', 32768:'TA', 32769:'DLV'}, unknown_qtype) CLASS = Bimap('CLASS', {1:'IN', 2:'CS', 3:'CH', 4:'Hesiod', 254:'None', 255:'*'}, @@ -276,7 +290,7 @@ def set_header_qa(self): """ - Reset header q/a/auth/ar counts to match numver of records + Reset header q/a/auth/ar counts to match number of records (normally done transparently) """ self.header.q = len(self.questions) @@ -709,7 +723,7 @@ def toZone(self): return ';%-30s %-7s %s' % (self.qname,CLASS.get(self.qclass), - QTYPE.get(self.qtype)) + QTYPE[self.qtype]) def __repr__(self): return "<DNS Question: '%s' qtype=%s qclass=%s>" % ( @@ -899,7 +913,7 @@ else: return '%-23s %-7s %-7s %-7s %s' % (self.rname,self.ttl, CLASS.get(self.rclass), - QTYPE.get(self.rtype), + QTYPE[self.rtype], self.rdata.toZone()) def __str__(self): @@ -981,7 +995,7 @@ To create a new RD type subclass this and add to RDMAP (below) - Subclass should implement (as a mininum): + Subclass should implement (as a minimum): parse (parse from packet data) __init__ (create class) @@ -1031,8 +1045,10 @@ """ Default 'repr' format should be equivalent to RD zone format """ - # For unknown rdata just default to hex - return binascii.hexlify(self.data).decode() + if len(self.data) > 0: + return "\\# %d %s" % (len(self.data), binascii.hexlify(self.data).decode().upper()) + else: + return "\\# 0" def toZone(self): return repr(self) @@ -1069,7 +1085,7 @@ class TXT(RD): """ DNS TXT record. Pass in either a single byte/unicode string, or a tuple/list of byte/unicode strings. - (byte strings are prefered as this avoids possible encoding issues) + (byte strings are preferred as this avoids possible encoding issues) >>> TXT(b'txtvers=1') "txtvers=1" @@ -1512,6 +1528,50 @@ attrs = ('order','preference','flags','service','regexp','replacement') +class DS(RD): + """ + DS (delegation signer) record as specified in RFC 4034 Section 5. + https://www.rfc-editor.org/rfc/rfc4034#section-5 + """ + + key_tag = H('key_tag') + algorithm = B('algorithm') + digest_type = B('digest_type') + + @classmethod + def parse(cls,buffer,length): + try: + (key_tag,algorithm,digest_type) = buffer.unpack("!HBB") + digest = buffer.get(length - 4) + return cls(key_tag,algorithm,digest_type,digest) + except (BufferError,BimapError) as e: + raise DNSError("Error unpacking DS [offset=%d]: %s" % + (buffer.offset,e)) + + @classmethod + def fromZone(cls,rd,origin=None): + return cls(int(rd[0]),int(rd[1]),int(rd[2]), + binascii.unhexlify("".join(rd[3:]).encode('ascii'))) + + def __init__(self,key_tag,algorithm,digest_type,digest): + self.key_tag = key_tag + self.algorithm = algorithm + self.digest_type = digest_type + self.digest = _force_bytes(digest) + + def pack(self,buffer): + buffer.pack("!HBB",self.key_tag,self.algorithm,self.digest_type) + buffer.append(self.digest) + + def __repr__(self): + return "%d %d %d %s" % ( + self.key_tag, + self.algorithm, + self.digest_type, + binascii.hexlify(self.digest).decode().upper()) + + attrs = ('key_tag','algorithm','digest_type','digest') + class DNSKEY(RD): flags = H('flags') @@ -1810,6 +1870,21 @@ >>> obj.pack(b) >>> b.data == pcap True + + # Issue 43: HTTPS reads after RD end + >>> msg = binascii.unhexlify("93088410000100020000000107646973636f726403636f6d0000410001c00c004100010000012c002b0001000001000c0268330568332d323902683200040014a29f80e9a29f87e8a29f88e8a29f89e8a29f8ae8c00c002e00010000012c005f00410d020000012c632834e5632575c586c907646973636f726403636f6d0044d488ce4a5b9085289c671f0296b2b06cffaca28880c57643befd43d6de433d84ae078b282fc2cdd744f3bea2f201042a7a0d6f3e17ebd887b082bbe30dfda100002904d0000080000000") + >>> print(DNSRecord.parse(msg)) + ;; ->>HEADER<<- opcode: QUERY, status: NOERROR, id: 37640 + ;; flags: qr aa cd; QUERY: 1, ANSWER: 2, AUTHORITY: 0, ADDITIONAL: 1 + ;; QUESTION SECTION: + ;discord.com. IN HTTPS + ;; ANSWER SECTION: + discord.com. 300 IN HTTPS 1 . alpn=h3,h3-29,h2 ipv4hint=162.159.128.233,162.159.135.232,162.159.136.232,162.159.137.232,162.159.138.232 + discord.com. 300 IN RRSIG HTTPS 13 2 300 20220919092245 20220917072245 34505 discord.com. RNSIzkpbkIUonGcfApaysGz/rKKIgMV2Q779Q9beQz2ErgeLKC/CzddE876i8gEEKnoNbz4X69iHsIK74w39oQ== + ;; ADDITIONAL SECTION: + ;; OPT PSEUDOSECTION + ; EDNS: version: 0, flags: do; udp: 1232 + """ attrs = ('priority', 'target', 'params') @@ -1822,6 +1897,7 @@ @classmethod def parse(cls,buffer,length): try: + end = buffer.offset + length priority, = buffer.unpack("!H") target = [] while True: @@ -1831,14 +1907,14 @@ seg = bytearray(buffer.get(n)) target.append(seg) params = [] - while buffer.remaining() > 0: + while buffer.offset < end: k, = buffer.unpack("!H") n, = buffer.unpack("!H") v = bytearray(buffer.get(n)) params.append((k, v)) return cls(priority, target, params) except (BufferError,BimapError) as e: - raise DNSError("Error unpacking HTTPS: " + str(e) + buffer.data[buffer.offset:].hex()) + raise DNSError("Error unpacking HTTPS: " + str(e) + str(binascii.hexlify(buffer.data[buffer.offset:]))) def pack(self,buffer): buffer.pack("!H", self.priority) @@ -2087,13 +2163,98 @@ targ = ".".join([self.zf_tostr(t) for t in self.target]) + "." return " ".join([pri, targ] + [self.zf_format_param(k, v) for k,v in self.params]) +class SSHFP(RD): + """ + SSHFP record as specified in RFC 4255 + https://www.rfc-editor.org/rfc/rfc4255.html + """ + + algorithm = B('algorithm') + fp_type = B('fp_type') + + @classmethod + def parse(cls,buffer,length): + try: + (algorithm,fp_type) = buffer.unpack("!BB") + fingerprint = buffer.get(length - 2) + return cls(algorithm,fp_type,fingerprint) + except (BufferError,BimapError) as e: + raise DNSError("Error unpacking DS [offset=%d]: %s" % + (buffer.offset,e)) + + @classmethod + def fromZone(cls,rd,origin=None): + return cls(int(rd[0]),int(rd[1]), + binascii.unhexlify("".join(rd[2:]).encode('ascii'))) + + def __init__(self,algorithm,fp_type,fingerprint): + self.algorithm = algorithm + self.fp_type = fp_type + self.fingerprint = _force_bytes(fingerprint) + + def pack(self,buffer): + buffer.pack("!BB",self.algorithm,self.fp_type) + buffer.append(self.fingerprint) + + def __repr__(self): + return "%d %d %s" % ( + self.algorithm, + self.fp_type, + binascii.hexlify(self.fingerprint).decode().upper()) + + attrs = ('algorithm','fp_type','fingerprint') + +class TLSA(RD): + """ + TLSA record as specified in RFC 6698 + https://www.rfc-editor.org/rfc/rfc6698 + """ + + cert_usage = B('cert_usage') + selector = B('selector') + matching_type = B('matching_type') + + @classmethod + def parse(cls,buffer,length): + try: + (cert_usage,selector,matching_type) = buffer.unpack("!BBB") + cert_data = buffer.get(length - 3) + return cls(cert_usage,selector,matching_type,cert_data) + except (BufferError,BimapError) as e: + raise DNSError("Error unpacking DS [offset=%d]: %s" % + (buffer.offset,e)) + + @classmethod + def fromZone(cls,rd,origin=None): + return cls(int(rd[0]),int(rd[1]),int(rd[2]), + binascii.unhexlify("".join(rd[3:]).encode('ascii'))) + + def __init__(self,cert_usage,selector,matching_type,cert_data): + self.cert_usage = cert_usage + self.selector = selector + self.matching_type = matching_type + self.cert_data = _force_bytes(cert_data) + + def pack(self,buffer): + buffer.pack("!BBB",self.cert_usage,self.selector,self.matching_type) + buffer.append(self.cert_data) + + def __repr__(self): + return "%d %d %d %s" % ( + self.cert_usage, + self.selector, + self.matching_type, + binascii.hexlify(self.cert_data).decode().upper()) + + attrs = ('cert_usage','selector','matching_type','cert_data') + # Map from RD type to class (used to pack/unpack records) # If you add a new RD class you must add to RDMAP RDMAP = { 'CNAME':CNAME, 'A':A, 'AAAA':AAAA, 'TXT':TXT, 'MX':MX, 'PTR':PTR, 'SOA':SOA, 'NS':NS, 'NAPTR': NAPTR, 'SRV':SRV, 'DNSKEY':DNSKEY, 'RRSIG':RRSIG, 'NSEC':NSEC, 'CAA':CAA, - 'HTTPS': HTTPS + 'HTTPS': HTTPS, 'DS':DS, 'SSHFP':SSHFP, 'TLSA':TLSA } ## diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/dnslib-0.9.20/dnslib/test/example.org-DS new/dnslib-0.9.23/dnslib/test/example.org-DS --- old/dnslib-0.9.20/dnslib/test/example.org-DS 1970-01-01 01:00:00.000000000 +0100 +++ new/dnslib-0.9.23/dnslib/test/example.org-DS 2022-10-28 19:18:20.000000000 +0200 @@ -0,0 +1,20 @@ +;; Sending: +;; QUERY: f1c001000001000000000000076578616d706c65036f726700002b0001 +;; ->>HEADER<<- opcode: QUERY, status: NOERROR, id: 61888 +;; flags: rd; QUERY: 1, ANSWER: 0, AUTHORITY: 0, ADDITIONAL: 0 +;; QUESTION SECTION: +;example.org. IN DS + +;; Got answer: +;; RESPONSE: f1c081800001000600000000076578616d706c65036f726700002b0001c00c002b000100000e10001893940801b4a5cce8d82dc585e327e5896eae82e0b9a76dc6c00c002b000100000e1000240d450802ed1168604bc6a14068b9905401e62698bb3663b6ec2073ebd3599b882a785bf6c00c002b000100000e1000187b6508017b8370002875dda781390a8e586c31493847d9bcc00c002b000100000e10002493940802d96afa9022000d368b5f497877df289a1e9a13a1ab1f97bc1bf4d5de16879134c00c002b000100000e1000180d450801dee10345942c98711eb058b25a749ee342fce1dcc00c002b000100000e1000247b6508023fdc4c11fa3ad3535ea8c1ce3eaf7bfa5ca9ae8a834d98fee10085cfaeb625aa +;; ->>HEADER<<- opcode: QUERY, status: NOERROR, id: 61888 +;; flags: qr rd ra; QUERY: 1, ANSWER: 6, AUTHORITY: 0, ADDITIONAL: 0 +;; QUESTION SECTION: +;example.org. IN DS +;; ANSWER SECTION: +example.org. 3600 IN DS 37780 8 1 B4A5CCE8D82DC585E327E5896EAE82E0B9A76DC6 +example.org. 3600 IN DS 3397 8 2 ED1168604BC6A14068B9905401E62698BB3663B6EC2073EBD3599B882A785BF6 +example.org. 3600 IN DS 31589 8 1 7B8370002875DDA781390A8E586C31493847D9BC +example.org. 3600 IN DS 37780 8 2 D96AFA9022000D368B5F497877DF289A1E9A13A1AB1F97BC1BF4D5DE16879134 +example.org. 3600 IN DS 3397 8 1 DEE10345942C98711EB058B25A749EE342FCE1DC +example.org. 3600 IN DS 31589 8 2 3FDC4C11FA3AD3535EA8C1CE3EAF7BFA5CA9AE8A834D98FEE10085CFAEB625AA diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/dnslib-0.9.20/dnslib/test/fedoraproject.org-TLSA new/dnslib-0.9.23/dnslib/test/fedoraproject.org-TLSA --- old/dnslib-0.9.20/dnslib/test/fedoraproject.org-TLSA 1970-01-01 01:00:00.000000000 +0100 +++ new/dnslib-0.9.23/dnslib/test/fedoraproject.org-TLSA 2022-10-28 19:18:20.000000000 +0200 @@ -0,0 +1,15 @@ +;; Sending: +;; QUERY: 77cc01000001000000000000045f343433045f7463700d6665646f726170726f6a656374036f72670000340001 +;; ->>HEADER<<- opcode: QUERY, status: NOERROR, id: 30668 +;; flags: rd; QUERY: 1, ANSWER: 0, AUTHORITY: 0, ADDITIONAL: 0 +;; QUESTION SECTION: +;_443._tcp.fedoraproject.org. IN TLSA + +;; Got answer: +;; RESPONSE: 77cc81800001000100000000045f343433045f7463700d6665646f726170726f6a656374036f72670000340001c00c003400010000012c0023010101a268847da80175457baf603df3b0ab9cc99d1f6bb84b83c351f97e9e6f397bb4 +;; ->>HEADER<<- opcode: QUERY, status: NOERROR, id: 30668 +;; flags: qr rd ra; QUERY: 1, ANSWER: 1, AUTHORITY: 0, ADDITIONAL: 0 +;; QUESTION SECTION: +;_443._tcp.fedoraproject.org. IN TLSA +;; ANSWER SECTION: +_443._tcp.fedoraproject.org. 300 IN TLSA 1 1 1 A268847DA80175457BAF603DF3B0AB9CC99D1F6BB84B83C351F97E9E6F397BB4 diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/dnslib-0.9.20/dnslib/test/oilpro.ch-TYPE65534 new/dnslib-0.9.23/dnslib/test/oilpro.ch-TYPE65534 --- old/dnslib-0.9.20/dnslib/test/oilpro.ch-TYPE65534 1970-01-01 01:00:00.000000000 +0100 +++ new/dnslib-0.9.23/dnslib/test/oilpro.ch-TYPE65534 2022-10-27 19:57:03.000000000 +0200 @@ -0,0 +1,17 @@ +;; Sending: +;; QUERY: 536601000001000000000000066f696c70726f02636800fffe0001 +;; ->>HEADER<<- opcode: QUERY, status: NOERROR, id: 21350 +;; flags: rd; QUERY: 1, ANSWER: 0, AUTHORITY: 0, ADDITIONAL: 0 +;; QUESTION SECTION: +;oilpro.ch. IN TYPE65534 + +;; Got answer: +;; RESPONSE: 536681800001000200000000066f696c70726f02636800fffe0001c00cfffe00010000000000050dd5c60001c00cfffe00010000000000050d2a680001 +;; ->>HEADER<<- opcode: QUERY, status: NOERROR, id: 21350 +;; flags: qr rd ra; QUERY: 1, ANSWER: 2, AUTHORITY: 0, ADDITIONAL: 0 +;; QUESTION SECTION: +;oilpro.ch. IN TYPE65534 +;; ANSWER SECTION: +oilpro.ch. 0 IN TYPE65534 \# 5 0DD5C60001 +oilpro.ch. 0 IN TYPE65534 \# 5 0D2A680001 + diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/dnslib-0.9.20/dnslib/test/openssl.org-TLSA new/dnslib-0.9.23/dnslib/test/openssl.org-TLSA --- old/dnslib-0.9.20/dnslib/test/openssl.org-TLSA 1970-01-01 01:00:00.000000000 +0100 +++ new/dnslib-0.9.23/dnslib/test/openssl.org-TLSA 2022-10-28 19:18:20.000000000 +0200 @@ -0,0 +1,15 @@ +;; Sending: +;; QUERY: 30b801000001000000000000045f353837045f746370036d7461076f70656e73736c036f72670000340001 +;; ->>HEADER<<- opcode: QUERY, status: NOERROR, id: 12472 +;; flags: rd; QUERY: 1, ANSWER: 0, AUTHORITY: 0, ADDITIONAL: 0 +;; QUESTION SECTION: +;_587._tcp.mta.openssl.org. IN TLSA + +;; Got answer: +;; RESPONSE: 30b881800001000100000000045f353837045f746370036d7461076f70656e73736c036f72670000340001c00c0034000100000e1000230301016cf12d78fbf242909d01b96ab5590812954058dc32f8415f048fff064291921e +;; ->>HEADER<<- opcode: QUERY, status: NOERROR, id: 12472 +;; flags: qr rd ra; QUERY: 1, ANSWER: 1, AUTHORITY: 0, ADDITIONAL: 0 +;; QUESTION SECTION: +;_587._tcp.mta.openssl.org. IN TLSA +;; ANSWER SECTION: +_587._tcp.mta.openssl.org. 3600 IN TLSA 3 1 1 6CF12D78FBF242909D01B96AB5590812954058DC32F8415F048FFF064291921E diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/dnslib-0.9.20/dnslib/test/salsa.debian.org-SSHFP new/dnslib-0.9.23/dnslib/test/salsa.debian.org-SSHFP --- old/dnslib-0.9.20/dnslib/test/salsa.debian.org-SSHFP 1970-01-01 01:00:00.000000000 +0100 +++ new/dnslib-0.9.23/dnslib/test/salsa.debian.org-SSHFP 2022-10-28 19:18:20.000000000 +0200 @@ -0,0 +1,18 @@ +;; Sending: +;; QUERY: 5afb010000010000000000000573616c73610664656269616e036f726700002c0001 +;; ->>HEADER<<- opcode: QUERY, status: NOERROR, id: 23291 +;; flags: rd; QUERY: 1, ANSWER: 0, AUTHORITY: 0, ADDITIONAL: 0 +;; QUESTION SECTION: +;salsa.debian.org. IN SSHFP + +;; Got answer: +;; RESPONSE: 5afb818000010004000000000573616c73610664656269616e036f726700002c0001c00c002c00010000025800160401676b02929dc7908278bcee876ea0f1640b8264e0c00c002c000100000258002204023800f7a464b070e0c8b61c45fb3211bcf4d9f1408901823be44e365c37c6afcec00c002c00010000025800160101eaa6c147facf35bc49946d9e8b90e2235c7da361c00c002c00010000025800220102f3c03414b13a6df37a3296b81774ec3e28d92e7c003667ca8e17d88433820a70 +;; ->>HEADER<<- opcode: QUERY, status: NOERROR, id: 23291 +;; flags: qr rd ra; QUERY: 1, ANSWER: 4, AUTHORITY: 0, ADDITIONAL: 0 +;; QUESTION SECTION: +;salsa.debian.org. IN SSHFP +;; ANSWER SECTION: +salsa.debian.org. 600 IN SSHFP 4 1 676B02929DC7908278BCEE876EA0F1640B8264E0 +salsa.debian.org. 600 IN SSHFP 4 2 3800F7A464B070E0C8B61C45FB3211BCF4D9F1408901823BE44E365C37C6AFCE +salsa.debian.org. 600 IN SSHFP 1 1 EAA6C147FACF35BC49946D9E8B90E2235C7DA361 +salsa.debian.org. 600 IN SSHFP 1 2 F3C03414B13A6DF37A3296B81774EC3E28D92E7C003667CA8E17D88433820A70 diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/dnslib-0.9.20/dnslib.egg-info/PKG-INFO new/dnslib-0.9.23/dnslib.egg-info/PKG-INFO --- old/dnslib-0.9.20/dnslib.egg-info/PKG-INFO 2022-07-17 23:58:50.000000000 +0200 +++ new/dnslib-0.9.23/dnslib.egg-info/PKG-INFO 2022-10-28 19:28:52.000000000 +0200 @@ -1,6 +1,6 @@ Metadata-Version: 2.1 Name: dnslib -Version: 0.9.20 +Version: 0.9.23 Summary: Simple library to encode/decode DNS wire-format packets Home-page: https://github.com/paulc/dnslib Author: PaulC @@ -390,6 +390,16 @@ Fix display of non-printable characters in TXT records (Issue #32 - thanks to @sbv-csis) Add --strip-aaaa option to dnslib.proxy + * 0.9.21 2022-09-19 Minor clean-up / add wheels to distro + * 0.9.22 2022-09027 Issue #43 (0.9.21 Raises TypeError instead of DNSError when failing to parse HTTPS records) + Note that we just fix the exception - there still seems to be a problem with parsing HTTPS records + (Thanks to @robinlandstrom) + * 0.9.23 2022-10-28 Issue #43: HTTPS reads after RD end (thanks to @robinlandstrom for pull request) + Issue #45: Dnslib fails to handle unknown RR types in NSEC RD type bitmap + Bimap now supports a function to map unknown types which we use to + dynamically map from rtype <-> TYPExxxx for unknown record types + RR zone representation updated to match RFC3597 + Pull Request #47: Add support for DS, SSHFP, and TLSA records (thanks to @rmbolger) License: -------- diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/dnslib-0.9.20/dnslib.egg-info/SOURCES.txt new/dnslib-0.9.23/dnslib.egg-info/SOURCES.txt --- old/dnslib-0.9.20/dnslib.egg-info/SOURCES.txt 2022-07-17 23:58:51.000000000 +0200 +++ new/dnslib-0.9.23/dnslib.egg-info/SOURCES.txt 2022-10-28 19:28:52.000000000 +0200 @@ -45,9 +45,11 @@ dnslib/test/cloudflare.com-TXT dnslib/test/cloudflare.com-TXT-dnssec dnslib/test/example.org-DNSKEY +dnslib/test/example.org-DS dnslib/test/example.org-MX-dnssec dnslib/test/example.org-PTR-dnssec dnslib/test/example.org-SOA-dnssec +dnslib/test/fedoraproject.org-TLSA dnslib/test/google.com-MX dnslib/test/google.com-NS dnslib/test/google.com-SOA @@ -70,6 +72,9 @@ dnslib/test/iana.org-SOA-dnssec dnslib/test/iana.org-TXT dnslib/test/iana.org-TXT-dnssec +dnslib/test/oilpro.ch-TYPE65534 +dnslib/test/openssl.org-TLSA +dnslib/test/salsa.debian.org-SSHFP dnslib/test/sip2sip.info-NAPTR dnslib/test/www.example.org-A-dnssec dnslib/test/www.example.org-AAAA-dnssec diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/dnslib-0.9.20/setup.py new/dnslib-0.9.23/setup.py --- old/dnslib-0.9.20/setup.py 2020-05-31 16:39:09.000000000 +0200 +++ new/dnslib-0.9.23/setup.py 2022-10-28 19:26:08.000000000 +0200 @@ -1,5 +1,23 @@ #!/usr/bin/env python +# To update PyPi version: +# +# (Make sure you have updated version and changelog in __init__.py) +# +# ./run_tests.sh +# python3 setup.py readme +# git commit -am ... +# git push +# git tag -a <version> -m <message> +# git push --tags +# (Create release from tag on Github) +# +# rm -rf dist +# python3 setup.py sdist +# python3 setup.py bdist_wheel +# python2 setup.py bdist_wheel +# twine upload + try: from setuptools import Command, setup except ImportError: