Bug 36034: (bug 34893 follow-up) fix capture of return values from checkpw
Adapt code to the change of return value type of checkpw introduced in bug 34893 Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org> Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
This commit is contained in:
parent
252ccbabc8
commit
3280e5a99d
1 changed files with 6 additions and 3 deletions
|
@ -1031,7 +1031,8 @@ sub checkauth {
|
||||||
unless ($shibSuccess) {
|
unless ($shibSuccess) {
|
||||||
if ( $cas && $query->param('ticket') ) {
|
if ( $cas && $query->param('ticket') ) {
|
||||||
my $retuserid;
|
my $retuserid;
|
||||||
( $return, $cardnumber, $retuserid, $cas_ticket ) =
|
my $patron;
|
||||||
|
( $return, $cardnumber, $retuserid, $patron, $cas_ticket ) =
|
||||||
checkpw( $userid, $password, $query, $type );
|
checkpw( $userid, $password, $query, $type );
|
||||||
$userid = $retuserid;
|
$userid = $retuserid;
|
||||||
$info{'invalidCasLogin'} = 1 unless ($return);
|
$info{'invalidCasLogin'} = 1 unless ($return);
|
||||||
|
@ -1099,8 +1100,9 @@ sub checkauth {
|
||||||
&& $q_userid eq C4::Context->preference('AutoSelfCheckID') )
|
&& $q_userid eq C4::Context->preference('AutoSelfCheckID') )
|
||||||
)
|
)
|
||||||
{
|
{
|
||||||
|
my $patron;
|
||||||
|
|
||||||
( $return, $cardnumber, $retuserid, $cas_ticket ) =
|
( $return, $cardnumber, $retuserid, $patron, $cas_ticket ) =
|
||||||
checkpw( $q_userid, $password, $query, $type );
|
checkpw( $q_userid, $password, $query, $type );
|
||||||
$userid = $retuserid if ($retuserid);
|
$userid = $retuserid if ($retuserid);
|
||||||
$info{'invalid_username_or_password'} = 1 unless ($return);
|
$info{'invalid_username_or_password'} = 1 unless ($return);
|
||||||
|
@ -1593,7 +1595,8 @@ sub check_api_auth {
|
||||||
return ( "failed", undef, undef );
|
return ( "failed", undef, undef );
|
||||||
}
|
}
|
||||||
my $newuserid;
|
my $newuserid;
|
||||||
( $return, $cardnumber, $newuserid, $cas_ticket ) = checkpw( $userid, $password, $query );
|
my $patron;
|
||||||
|
( $return, $cardnumber, $newuserid, $patron, $cas_ticket ) = checkpw( $userid, $password, $query );
|
||||||
}
|
}
|
||||||
|
|
||||||
if ( $return and haspermission( $userid, $flagsrequired ) ) {
|
if ( $return and haspermission( $userid, $flagsrequired ) ) {
|
||||||
|
|
Loading…
Reference in a new issue