Skip to content
Snippets Groups Projects
Commit 7eb8f287 authored by Kyra ツ's avatar Kyra ツ
Browse files

Fix XSS Vulnerability In "tpl.inc.php"

Fix applied to where the value is directly output to browser instead of where fetched in case special chars are allowed in `code_name`, which may break logic prior to output.
parent 356ca50b
No related branches found
No related tags found
No related merge requests found
......@@ -77,7 +77,7 @@ $tpl=$msgtemplates[$selected];
<form action="templates.php?id=<?php echo $id; ?>&amp;a=manage" method="post" id="save">
<?php csrf_token(); ?>
<?php foreach ($extras as $k=>$v) { ?>
<input type="hidden" name="<?php echo $k; ?>" value="<?php echo $v; ?>" />
<input type="hidden" name="<?php echo $k; ?>" value="<?php echo Format::htmlchars($v); ?>" />
<?php } ?>
<input type="hidden" name="id" value="<?php echo $id; ?>">
<input type="hidden" name="a" value="manage">
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment