ifcfg-rh: unescape ifcfg value for CIPHER_GROUP/CIPHER_PAIRWISE

It's not clear why we would read the CIPHER_GROUP/CIPHER_PAIRWISE
verbatim=TRUE (without shell unescaping). Especially since ifcfg-rh
writer does
  svSetValue (ifcfg, "CIPHER_PAIRWISE", str->str, FALSE);
This commit is contained in:
Thomas Haller
2016-10-27 19:12:30 +02:00
parent 8f9432327c
commit 22ef66e6bb

View File

@@ -2358,16 +2358,10 @@ fill_wpa_ciphers (shvarFile *ifcfg,
char **list = NULL, **iter; char **list = NULL, **iter;
int i = 0; int i = 0;
p = value = svGetValue (ifcfg, group ? "CIPHER_GROUP" : "CIPHER_PAIRWISE", TRUE); p = value = svGetValue (ifcfg, group ? "CIPHER_GROUP" : "CIPHER_PAIRWISE", FALSE);
if (!value) if (!value)
return TRUE; return TRUE;
/* Strip quotes */
if (p[0] == '"')
p++;
if (p[strlen (p) - 1] == '"')
p[strlen (p) - 1] = '\0';
list = g_strsplit_set (p, " ", 0); list = g_strsplit_set (p, " ", 0);
for (iter = list; iter && *iter; iter++, i++) { for (iter = list; iter && *iter; iter++, i++) {
/* Ad-Hoc configurations cannot have pairwise ciphers, and can only /* Ad-Hoc configurations cannot have pairwise ciphers, and can only