mirror of
https://github.com/roundcube/roundcubemail.git
synced 2026-03-23 08:16:57 +01:00
* Fix "method_argument_space" * Fix "control_structure_continuation_position" * Fix "new_with_parentheses" * Fix "blank_line_before_statement" * Fix "visibility_required" * Fix some "array_indentation" * Fix some "array_indentation" - unify all "rcube::raise_error" calls * rm useless eslint ignores and add rules counts * sort eslint ignores * fix eslint ignores grammar * Revert "Fix "blank_line_before_statement"" * fix CS 3.46.0
21 lines
507 B
PHP
21 lines
507 B
PHP
<?php
|
|
|
|
/**
|
|
* Test class to test rcmail_attachment_handler class
|
|
*/
|
|
class Rcmail_RcmailAttachmentHandler extends ActionTestCase
|
|
{
|
|
/**
|
|
* Test rcmail_action::svg_filter()
|
|
*/
|
|
public function test_svg_filter()
|
|
{
|
|
$svg = '<svg><a xlink:href="javascript:alert(1)"><text x="20" y="20">XSS</text></a></svg>';
|
|
$exp = '<svg><a><text x="20" y="20">XSS</text></a></svg>';
|
|
|
|
$out = rcmail_attachment_handler::svg_filter($svg);
|
|
|
|
$this->assertSame($exp, $out);
|
|
}
|
|
}
|