NAME
Catalyst::Plugin::StripScripts - XSS filter plugin
SYNOPSIS
# In App.pm
__PACKAGE__->config({
strip_scripts
=> [
{
Context
=>
'Inline'
,
},
strict_comment
=> 1,
strict_names
=> 1,
] });
# In App/Controller/YourController.pm
sub
index
: Private {
my
(
$self
,
$c
) =
@_
;
$c
->strip_scripts(
$html
);
$c
->forward(
'View::TT'
);
}
DESCRIPTION
This module adds the ability of removing unwanted html tags from your website output. It is based on HTML::StripScripts::Parser. The configurations in App.pm will be used when you invoke strip_scripts.
LICENSE
This library is free software; you can redistribute it and/or modify it under the same terms as Perl itself.
AUTHOR
Yung-chung Lin (henearkrxern@gmail.com)