summaryrefslogtreecommitdiffstats
path: root/etc/inc/xmlparse.inc
diff options
context:
space:
mode:
authorjim-p <jimp@pfsense.org>2011-01-06 13:53:38 -0500
committerjim-p <jimp@pfsense.org>2011-01-06 13:53:38 -0500
commit72b7aa4a8ebb397c21f923cc43a2fa6071a907e6 (patch)
tree28b3b06128619adb611fb57ac75ba13119b76cba /etc/inc/xmlparse.inc
parentd865241eddda66e39cea4e1408171f83d593b3d2 (diff)
downloadpfsense-72b7aa4a8ebb397c21f923cc43a2fa6071a907e6.zip
pfsense-72b7aa4a8ebb397c21f923cc43a2fa6071a907e6.tar.gz
Also CDATA protect the detail field. Fixes #1168
Diffstat (limited to 'etc/inc/xmlparse.inc')
-rw-r--r--etc/inc/xmlparse.inc4
1 files changed, 2 insertions, 2 deletions
diff --git a/etc/inc/xmlparse.inc b/etc/inc/xmlparse.inc
index 75871a9..3e32d68 100644
--- a/etc/inc/xmlparse.inc
+++ b/etc/inc/xmlparse.inc
@@ -229,7 +229,7 @@ function dump_xml_config_sub($arr, $indent) {
$xmlconfig .= str_repeat("\t", $indent);
if((is_bool($cval) && $cval == true) || ($cval === "")) {
$xmlconfig .= "<$ent/>\n";
- } else if (substr($ent, 0, 5) == "descr") {
+ } else if ((substr($ent, 0, 5) == "descr") || (substr($ent, 0, 6) == "detail")) {
$xmlconfig .= "<$ent><![CDATA[" . htmlentities($cval) . "]]></$ent>\n";
} else {
$xmlconfig .= "<$ent>" . htmlentities($cval) . "</$ent>\n";
@@ -253,7 +253,7 @@ function dump_xml_config_sub($arr, $indent) {
$xmlconfig .= "<$ent/>\n";
} else if (!is_bool($val)) {
$xmlconfig .= str_repeat("\t", $indent);
- if (substr($ent, 0, 5) == "descr")
+ if ((substr($ent, 0, 5) == "descr") || (substr($ent, 0, 6) == "detail"))
$xmlconfig .= "<$ent><![CDATA[" . htmlentities($val) . "]]></$ent>\n";
else
$xmlconfig .= "<$ent>" . htmlentities($val) . "</$ent>\n";
OpenPOWER on IntegriCloud