#1386 - Fix warnings
This commit is contained in:
parent
869166cb31
commit
53752276e4
|
@ -1,4 +1,4 @@
|
|||
# Self U2F registration
|
||||
# Self TOTP registration
|
||||
package Lemonldap::NG::Portal::2F::Register::TOTP;
|
||||
|
||||
use strict;
|
||||
|
@ -94,13 +94,14 @@ sub run {
|
|||
{ _totp2fSecret => $token->{_totp2fSecret} } );
|
||||
|
||||
my $list2FDevices = eval {
|
||||
$self->logger->debug("Looking for 2F Devices ...");
|
||||
from_json( $req->userData->{list2FDevices}, { allow_nonref => 1 } );
|
||||
};
|
||||
unless ($list2FDevices) {
|
||||
$self->logger->debug("No 2F Device found");
|
||||
$list2FDevices = [];
|
||||
}
|
||||
push $list2FDevices,
|
||||
push @{$list2FDevices},
|
||||
{
|
||||
type => 'totp',
|
||||
name => $TOTPName,
|
||||
|
|
|
@ -65,6 +65,7 @@ sub run {
|
|||
if ( $keyHandle and $userKey ) {
|
||||
|
||||
my $list2FDevices = eval {
|
||||
$self->logger->debug("Looking for 2F Devices ...");
|
||||
from_json( $req->userData->{list2FDevices},
|
||||
{ allow_nonref => 1 } );
|
||||
};
|
||||
|
@ -73,7 +74,7 @@ sub run {
|
|||
$list2FDevices = [];
|
||||
}
|
||||
my $keyName = $req->param('keyName');
|
||||
push $list2FDevices,
|
||||
push @{$list2FDevices},
|
||||
{
|
||||
type => 'U2F',
|
||||
name => $keyName,
|
||||
|
|
|
@ -1,3 +1,4 @@
|
|||
# Self Yubikey registration
|
||||
package Lemonldap::NG::Portal::2F::Register::Yubikey;
|
||||
|
||||
use strict;
|
||||
|
@ -44,6 +45,7 @@ sub run {
|
|||
|
||||
my $key = substr( $otp, 0, $self->conf->{yubikey2fPublicIDSize} );
|
||||
my $list2FDevices = eval {
|
||||
$self->logger->debug("Looking for 2F Devices ...");
|
||||
from_json( $req->userData->{list2FDevices},
|
||||
{ allow_nonref => 1 } );
|
||||
};
|
||||
|
@ -51,7 +53,7 @@ sub run {
|
|||
$self->logger->debug("No 2F Device found");
|
||||
$list2FDevices = [];
|
||||
}
|
||||
push $list2FDevices,
|
||||
push @{$list2FDevices},
|
||||
{
|
||||
type => 'UBK',
|
||||
name => $UBKName,
|
||||
|
|
Loading…
Reference in New Issue
Block a user