Prevent any problematic character being stored in /etc/config and /etc/config.mesh (#1463)

* Remove any problematic character being stored in our config files.
Any specific escaping needs to take place in context. This just
stops them becoming a problem.
This commit is contained in:
Tim Wilkinson 2024-09-05 18:24:58 -07:00 committed by GitHub
parent 319b0f2153
commit f5ef0ecd7b
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
1 changed files with 2 additions and 2 deletions

View File

@ -196,7 +196,7 @@ const uciMethods =
cursor.set(a, b, c); cursor.set(a, b, c);
} }
else { else {
cursor.set(a, b, c, d); cursor.set(a, b, c, replace(d, "'", ""));
} }
}, },
@ -263,7 +263,7 @@ const uciMeshMethods =
cursorm.set(a, b, c); cursorm.set(a, b, c);
} }
else { else {
cursorm.set(a, b, c, d); cursorm.set(a, b, c, replace(d, /['<>]/g, ""));
} }
}, },