Lines 72-85
BEGIN {
Link Here
|
72 |
$ldap = C4::Context->config('useldapserver') || 0; |
72 |
$ldap = C4::Context->config('useldapserver') || 0; |
73 |
$cas = C4::Context->preference('casAuthentication'); |
73 |
$cas = C4::Context->preference('casAuthentication'); |
74 |
$caslogout = C4::Context->preference('casLogout'); |
74 |
$caslogout = C4::Context->preference('casLogout'); |
75 |
require C4::Auth_with_cas; # no import |
|
|
76 |
|
75 |
|
77 |
if ($ldap) { |
76 |
if ($ldap) { |
78 |
require C4::Auth_with_ldap; |
77 |
require C4::Auth_with_ldap; |
79 |
import C4::Auth_with_ldap qw(checkpw_ldap); |
78 |
import C4::Auth_with_ldap qw(checkpw_ldap); |
80 |
} |
79 |
} |
81 |
if ($cas) { |
80 |
if ($cas) { |
82 |
import C4::Auth_with_cas qw(check_api_auth_cas checkpw_cas login_cas logout_cas login_cas_url logout_if_required); |
81 |
require C4::Auth_with_cas; # no import |
|
|
82 |
import C4::Auth_with_cas qw(check_api_auth_cas checkpw_cas login_cas logout_cas login_cas_url logout_if_required multipleAuth getMultipleAuth); |
83 |
} |
83 |
} |
84 |
|
84 |
|
85 |
} |
85 |
} |
Lines 1392-1399
sub checkauth {
Link Here
|
1392 |
if ($cas) { |
1392 |
if ($cas) { |
1393 |
|
1393 |
|
1394 |
# Is authentication against multiple CAS servers enabled? |
1394 |
# Is authentication against multiple CAS servers enabled? |
1395 |
if ( C4::Auth_with_cas::multipleAuth && !$casparam ) { |
1395 |
require C4::Auth_with_cas; |
1396 |
my $casservers = C4::Auth_with_cas::getMultipleAuth(); |
1396 |
if ( multipleAuth() && !$casparam ) { |
|
|
1397 |
my $casservers = getMultipleAuth(); |
1397 |
my @tmplservers; |
1398 |
my @tmplservers; |
1398 |
foreach my $key ( keys %$casservers ) { |
1399 |
foreach my $key ( keys %$casservers ) { |
1399 |
push @tmplservers, { name => $key, value => login_cas_url( $query, $key, $type ) . "?cas=$key" }; |
1400 |
push @tmplservers, { name => $key, value => login_cas_url( $query, $key, $type ) . "?cas=$key" }; |