|
Lines 564-570
sub checkauth {
Link Here
|
| 564 |
$session->flush; |
564 |
$session->flush; |
| 565 |
$session->delete(); |
565 |
$session->delete(); |
| 566 |
C4::Context->_unset_userenv($sessionID); |
566 |
C4::Context->_unset_userenv($sessionID); |
| 567 |
_session_log(sprintf "%20s from %16s logged out at %30s (manually).\n", $userid,$ip,scalar localtime); |
567 |
_session_log(sprintf "%20s from %16s logged out at %30s (manually).\n", $userid,$ip,(strftime "%c",localtime)); |
| 568 |
$sessionID = undef; |
568 |
$sessionID = undef; |
| 569 |
$userid = undef; |
569 |
$userid = undef; |
| 570 |
} |
570 |
} |
|
Lines 573-579
sub checkauth {
Link Here
|
| 573 |
$info{'timed_out'} = 1; |
573 |
$info{'timed_out'} = 1; |
| 574 |
$session->delete(); |
574 |
$session->delete(); |
| 575 |
C4::Context->_unset_userenv($sessionID); |
575 |
C4::Context->_unset_userenv($sessionID); |
| 576 |
_session_log(sprintf "%20s from %16s logged out at %30s (inactivity).\n", $userid,$ip,scalar localtime); |
576 |
_session_log(sprintf "%20s from %16s logged out at %30s (inactivity).\n", $userid,$ip,(strftime "%c",localtime)); |
| 577 |
$userid = undef; |
577 |
$userid = undef; |
| 578 |
$sessionID = undef; |
578 |
$sessionID = undef; |
| 579 |
} |
579 |
} |
|
Lines 584-590
sub checkauth {
Link Here
|
| 584 |
$info{'different_ip'} = 1; |
584 |
$info{'different_ip'} = 1; |
| 585 |
$session->delete(); |
585 |
$session->delete(); |
| 586 |
C4::Context->_unset_userenv($sessionID); |
586 |
C4::Context->_unset_userenv($sessionID); |
| 587 |
_session_log(sprintf "%20s from %16s logged out at %30s (ip changed to %16s).\n", $userid,$ip,scalar localtime, $info{'newip'}); |
587 |
_session_log(sprintf "%20s from %16s logged out at %30s (ip changed to %16s).\n", $userid,$ip,(strftime "%c",localtime), $info{'newip'}); |
| 588 |
$sessionID = undef; |
588 |
$sessionID = undef; |
| 589 |
$userid = undef; |
589 |
$userid = undef; |
| 590 |
} |
590 |
} |
|
Lines 611-617
sub checkauth {
Link Here
|
| 611 |
my $password = $query->param('password'); |
611 |
my $password = $query->param('password'); |
| 612 |
my ( $return, $cardnumber ) = checkpw( $dbh, $userid, $password ); |
612 |
my ( $return, $cardnumber ) = checkpw( $dbh, $userid, $password ); |
| 613 |
if ($return) { |
613 |
if ($return) { |
| 614 |
_session_log(sprintf "%20s from %16s logged in at %30s.\n", $userid,$ENV{'REMOTE_ADDR'},scalar localtime); |
614 |
_session_log(sprintf "%20s from %16s logged in at %30s.\n", $userid,$ENV{'REMOTE_ADDR'},(strftime "%c",localtime)); |
| 615 |
if ( $flags = haspermission($userid, $flagsrequired) ) { |
615 |
if ( $flags = haspermission($userid, $flagsrequired) ) { |
| 616 |
$loggedin = 1; |
616 |
$loggedin = 1; |
| 617 |
} |
617 |
} |
| 618 |
- |
|
|