Skip to content

Commit

Permalink
Fix XSS on filter edit page (CVE-2018-14504)
Browse files Browse the repository at this point in the history
Teun Beijers reported a cross-site scripting (XSS) vulnerability in
the Edit Filter page which allows execution of arbitrary code
(if CSP settings permit it) when displaying a filter with a crafted
name.

Prevent the attack by sanitizing the filter name before display.

Fixes #24608
  • Loading branch information
atrol committed Jul 23, 2018
1 parent 4efac90 commit 8b5fa24
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion manage_filter_edit_page.php
Expand Up @@ -124,7 +124,7 @@
<div class="form-inline">
<label>
<?php echo lang_get( 'query_name' ) ?>&nbsp;
<input type="text" size="25" name="filter_name" maxlength="64" value="<?php echo filter_get_field( $f_filter_id, 'name' ) ?>">
<input type="text" size="25" name="filter_name" maxlength="64" value="<?php echo string_display_line( filter_get_field( $f_filter_id, 'name' ) ) ?>">
</label>
</div>
</div>
Expand Down

0 comments on commit 8b5fa24

Please sign in to comment.