Append URL test (#1532)

This commit is contained in:
Christophe Maudoux 2018-10-29 22:10:49 +01:00
parent badc7a0cad
commit 52a7f884f6

View File

@ -204,7 +204,9 @@ sub _buildAuthLoop {
# Default URL
if ( defined $url
and not $self->checkXSSAttack( 'URI',
$req->env->{'REQUEST_URI'} ) )
$req->env->{'REQUEST_URI'} )
and $url =~ m%^(https?://)?[^\s/$.?#].[^\s]*$%
)
{
$url .= $req->env->{'REQUEST_URI'};
$req->{cspFormAction} .= " $url";