From 0d4c16f0cacd1cfe7b890ad78f327a3a42f9302a Mon Sep 17 00:00:00 2001 From: Tom Van Braeckel Date: Mon, 25 Jan 2016 04:47:18 +0100 Subject: [PATCH] wicd: Fix the parsing and writing of wep-hex configurations (launchpad bug #1419464) Thanks, Axel Beckert from Debian! *** Symptom: Can't connect to WEP based networks with hexadecimal keys due to unexpanded template variables like $_KEY in the actual wpa_supplicant configurations. Solution: Move the appending of the line outside the loop over all matches in one line. Author: Axel Beckert Bug-Debian: https://bugs.debian.org/812427 Bug: https://bugs.launchpad.net/wicd/+bug/1419464 --- wicd/misc.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/wicd/misc.py b/wicd/misc.py index af71f26..508fef9 100644 --- a/wicd/misc.py +++ b/wicd/misc.py @@ -321,11 +321,11 @@ def ParseEncryption(network): rep_val = '0' if rep_val: line = line.replace("$_%s" % cur_val, str(rep_val)) - config_file = ''.join([config_file, line]) else: print "Ignoring template line: '%s'" % line else: print "Weird parsing error occurred" + config_file = ''.join([config_file, line]) else: # Just a regular entry. config_file = ''.join([config_file, line])