From: Michael Orlitzky Date: Fri, 5 Oct 2018 22:00:01 +0000 (-0400) Subject: bin/untangle-https-backup: disable configuration file interpolation. X-Git-Tag: 0.0.9~1 X-Git-Url: http://gitweb.michael.orlitzky.com/?p=untangle-https-backup.git;a=commitdiff_plain;h=6d2a0bc6de87d701a806912f4ca81840f0abe2a7 bin/untangle-https-backup: disable configuration file interpolation. It was bound to happen: somebody changed their password to something with a percent sign in it, and it broke the secret ConfigParser interpolation that I didn't know existed. Nobody is interpolating usernames or version numbers into their password fields (if you are; see you in hell), so passing interpolation=None to our ConfigParser instantiation should fix the issue. --- diff --git a/bin/untangle-https-backup b/bin/untangle-https-backup index 25fbf9d..3abb05f 100755 --- a/bin/untangle-https-backup +++ b/bin/untangle-https-backup @@ -31,8 +31,10 @@ args = parser.parse_args() # Default to success, change it if anything fails. status = EXIT_OK -# Parse the configuration file... -config = configparser.ConfigParser() +# Parse the configuration file. In this contect "interpolation" is +# something completely berserk, and it breaks passwords containing '%' +# characters. So, we turn it off. +config = configparser.ConfigParser(interpolation=None) config.read(args.config_file) # And loop through each section.