mirror of
https://github.com/php/php-src.git
synced 2024-10-19 07:22:40 +00:00
7d7248390c
Fixed possible double encoding problem with sanitizing filters Make use of space-strict strip_tags() function
11 lines
280 B
PHP
11 lines
280 B
PHP
--TEST--
|
|
Combination of strip & sanitize filters
|
|
--FILE--
|
|
<?php
|
|
$var = 'XYZ< script>alert(/ext/filter+bypass/);< /script>ABC';
|
|
$a = filter_var($var, FILTER_SANITIZE_STRING, array("flags" => FILTER_FLAG_STRIP_LOW));
|
|
echo $a . "\n";
|
|
?>
|
|
--EXPECT--
|
|
XYZalert(/ext/filter+bypass/);ABC
|