Skip to content

Commit a087b07

Browse files
committed
Fixes #6754 XSS issue in data log history detail page
1 parent bcb8eb1 commit a087b07

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

interface/web/monitor/dataloghistory_view.php

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -130,7 +130,7 @@
130130
foreach ($data['new'] as $key=>$value) {
131131
$inserts[] = array(
132132
'key' => $key,
133-
'value' => nl2br($value),
133+
'value' => nl2br($app->functions->htmlentities($value)),
134134
);
135135
}
136136
$app->tpl->setLoop('inserts', $inserts);
@@ -145,8 +145,8 @@
145145
$updates[] = array(
146146
'key' => $key,
147147
'is_diff' => $changes['is_diff'],
148-
'old' => nl2br($changes['old']),
149-
'new' => nl2br($changes['new']),
148+
'old' => nl2br($app->functions->htmlentities($changes['old'])),
149+
'new' => nl2br($app->functions->htmlentities($changes['new'])),
150150
'diff' => nl2br($changes['diff']),
151151
);
152152
}
@@ -162,7 +162,7 @@
162162
foreach ($data['old'] as $key=>$value) {
163163
$deletes[] = array(
164164
'key' => $key,
165-
'value' => nl2br($value),
165+
'value' => nl2br($app->functions->htmlentities($value)),
166166
);
167167
}
168168
$app->tpl->setLoop('deletes', $deletes);

0 commit comments

Comments
 (0)