Hide some warnings (#1487)
This commit is contained in:
parent
9b39f2e44c
commit
52348ecbb0
|
@ -307,8 +307,11 @@ sub _displayRegister {
|
|||
[] ];
|
||||
}
|
||||
|
||||
my $_2fDevices = eval { from_json( $req->userData->{_2fDevices},
|
||||
{ allow_nonref => 1 } ); };
|
||||
my $_2fDevices =
|
||||
$req->userData->{_2fDevices}
|
||||
? eval { from_json( $req->userData->{_2fDevices},
|
||||
{ allow_nonref => 1 } ); }
|
||||
: undef;
|
||||
|
||||
unless ($_2fDevices) {
|
||||
$self->logger->debug("No 2F Device found");
|
||||
|
|
|
@ -731,11 +731,13 @@ sub sendHtml {
|
|||
$csp .= " $url";
|
||||
}
|
||||
my $url = $args{params}->{URL};
|
||||
if ( defined $url ) {
|
||||
$self->logger->debug("Required Params URL : $url");
|
||||
if ( defined $url and $url =~ s#(https?://[^/]+).*#$1# ) {
|
||||
if ( $url =~ s#(https?://[^/]+).*#$1# ) {
|
||||
$self->logger->debug("Set CSP form-action with Params URL : $url");
|
||||
$csp .= " $url";
|
||||
}
|
||||
}
|
||||
$csp .= ';';
|
||||
|
||||
# Deny using portal in frame except if it is required
|
||||
|
|
Loading…
Reference in New Issue
Block a user