Stauros
一个快速的XSS消除PHP库.
With the default settings, simply callStauros->scanHTML():
$stauros = new Stauros;$clean = $stauros->scanHTML($dirty);
Easy as that
Stauros supports streaming content as well. You can use a stream as input, getting a string as output:
立即学习“PHP免费学习笔记(深入)”;
$clean = $stauros->scanHTMLStreamToString($stream);
Or you can use it as a stream to stream process:
$stauros->scanHTMLStreamToStream($input, $output);
The configuration class (Stauros\HTML\Config) allows you to specify html tag whitelists, as well as attribute whitelist and implement an attribute callback for further customization.
项目主页:http://www.open-open.com/lib/view/home/1441378271175
PHP怎么学习?PHP怎么入门?PHP在哪学?PHP怎么学才快?不用担心,这里为大家提供了PHP速学教程(入门到精通),有需要的小伙伴保存下载就能学习啦!
Copyright 2014-2025 https://www.php.cn/ All Rights Reserved | php.cn | 湘ICP备2023035733号