changeset 6295:bc2b00afa980

Replace depricated base64.decodestring with base64.b64decode.
author John Rouillard <rouilj@ieee.org>
date Mon, 14 Dec 2020 09:52:58 -0500
parents 48a0f724ffbc
children 6cf9f2f49b89
files CHANGES.txt roundup/scripts/roundup_server.py roundup/scripts/roundup_xmlrpc_server.py
diffstat 3 files changed, 5 insertions(+), 2 deletions(-) [+]
line wrap: on
line diff
--- a/CHANGES.txt	Sun Nov 29 16:11:22 2020 -0500
+++ b/CHANGES.txt	Mon Dec 14 09:52:58 2020 -0500
@@ -49,6 +49,9 @@
   as plain text. (John Rouillard)
 - issue2551100 - old jquery has security issues, upgrade it and fix
   user.help.html
+- replace deprecated base64.decodestring with base64.b64decode in
+  roundup_server.py and roundup_xlmrpc_server.py (reported by
+  lmsteffan in irc)
 
 Features:
 - issue2550522 - Add 'filter' command to command-line
--- a/roundup/scripts/roundup_server.py	Sun Nov 29 16:11:22 2020 -0500
+++ b/roundup/scripts/roundup_server.py	Mon Dec 14 09:52:58 2020 -0500
@@ -74,7 +74,7 @@
 # "default" favicon.ico
 # generate by using "icotool" and tools/base64
 import zlib, base64
-favico = zlib.decompress(base64.decodestring(b'''
+favico = zlib.decompress(base64.b64decode(b'''
 eJztjr1PmlEUh59XgVoshdYPWorFIhaRFq0t9pNq37b60lYSTRzcTFw6GAfj5gDYaF0dTB0MxMSE
 gQQd3FzKJiEC0UCIUUN1M41pV2JCXySg/0ITn5tfzvmdc+85FwT56HSc81UJjXJsk1UsNcsSqCk1
 BS64lK+vr7OyssLJyQl2ux2j0cjU1BQajYZIJEIwGMRms+H3+zEYDExOTjI2Nsbm5iZWqxWv18vW
--- a/roundup/scripts/roundup_xmlrpc_server.py	Sun Nov 29 16:11:22 2020 -0500
+++ b/roundup/scripts/roundup_xmlrpc_server.py	Mon Dec 14 09:52:58 2020 -0500
@@ -64,7 +64,7 @@
         scheme, challenge = authorization.split(' ', 1)
 
         if scheme.lower() == 'basic':
-            decoded = base64.decodestring(challenge)
+            decoded = base64.b64decode(challenge)
             if ':' in decoded:
                 username, password = decoded.split(':')
             else:

Roundup Issue Tracker: http://roundup-tracker.org/