From 4a46242ed2398ead2e9cd514f1f113527675cb37 Mon Sep 17 00:00:00 2001 From: Mark Andrews Date: Mon, 18 Feb 2019 16:36:59 +1100 Subject: [PATCH 1/2] explicitly convert byte to string (cherry picked from commit ec3d830bc50e43858c7982df9b9db95aa8cffca0) --- bin/python/isc/checkds.py.in | 4 ++++ bin/python/isc/keyzone.py.in | 2 ++ 2 files changed, 6 insertions(+) diff --git a/bin/python/isc/checkds.py.in b/bin/python/isc/checkds.py.in index cac226ee4d..b5cbe3fd05 100644 --- a/bin/python/isc/checkds.py.in +++ b/bin/python/isc/checkds.py.in @@ -107,6 +107,8 @@ def check(zone, args): fp, _ = Popen(cmd, stdout=PIPE).communicate() for line in fp.splitlines(): + if type(line) is not str: + line = line.decode('ascii') rrlist.append(SECRR(line, args.lookaside)) rrlist = sorted(rrlist, key=lambda rr: (rr.keyid, rr.keyalg, rr.hashalg)) @@ -128,6 +130,8 @@ def check(zone, args): fp, _ = Popen(cmd, stdin=PIPE, stdout=PIPE).communicate(intods) for line in fp.splitlines(): + if type(line) is not str: + line = line.decode('ascii') klist.append(SECRR(line, args.lookaside)) if len(klist) < 1: diff --git a/bin/python/isc/keyzone.py.in b/bin/python/isc/keyzone.py.in index 2451d439e4..bc8c51d72f 100644 --- a/bin/python/isc/keyzone.py.in +++ b/bin/python/isc/keyzone.py.in @@ -43,6 +43,8 @@ class keyzone: fp, _ = Popen([czpath, "-o", "-", name, filename], stdout=PIPE, stderr=PIPE).communicate() for line in fp.splitlines(): + if type(line) is not str: + line = line.decode('ascii') if re.search('^[:space:]*;', line): continue fields = line.split() From 36d91876bf5361ba863e44733cb290522dd2dd31 Mon Sep 17 00:00:00 2001 From: Evan Hunt Date: Wed, 6 Mar 2019 14:22:58 -0800 Subject: [PATCH 2/2] add CHANGES (cherry picked from commit 57e44efc735832976363a8d5b01290c3da0a5ce7) --- CHANGES | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/CHANGES b/CHANGES index 5d36842a86..712cf775c6 100644 --- a/CHANGES +++ b/CHANGES @@ -1,6 +1,10 @@ 5176. [tests] Remove a dependency on libxml in statschannel system test. [GL #926] +5175. [bug] Fixed a problem with file input in dnssec-keymgr, + dnssec-coverage and dnssec-checkds when using + python3. [GL #882] + 5174. [doc] Tidy dnssec-keygen manual. [GL !1557] 5173. [bug] Fixed a race in socket code that could occur when