INPUTS => \@inputs,
casAuthentication => C4::Context->preference("casAuthentication"),
shibbolethAuthentication => $shib,
+ SessionRestrictionByIP => C4::Context->preference("SessionRestrictionByIP"),
suggestion => C4::Context->preference("suggestion"),
virtualshelves => C4::Context->preference("virtualshelves"),
LibraryName => "" . C4::Context->preference("LibraryName"),
$userid = undef;
$sessionID = undef;
return ( "expired", undef, undef );
- } elsif ( $ip ne $ENV{'REMOTE_ADDR'} ) {
+ } elsif ( C4::Context->preference('SessionRestrictionByIP') && $ip ne $ENV{'REMOTE_ADDR'} ) {
# IP address changed
$session->delete();
C4::Context->_unset_userenv($sessionID);
$userid = undef;
$sessionID = undef;
- return ( "expired", undef );
- } elsif ( $ip ne $ENV{'REMOTE_ADDR'} ) {
+ return ("expired", undef);
+ } elsif ( C4::Context->preference('SessionRestrictionByIP') && $ip ne $ENV{'REMOTE_ADDR'} ) {
# IP address changed
$session->delete();
yes: Require
no: "Don't require"
- staff to log in from a computer in the IP address range <a href="/cgi-bin/koha/admin/branches.pl">specified by their library</a> (if any).
+ -
+ - pref: SessionRestrictionByIP
+ default: 0
+ choices:
+ yes: Enable
+ no: "Disable"
+ - Check for Change in Remote IP address for Session Security. Disable when remote ip address changes frequently.
# PostgreSQL is supported by CGI::Session but not by Koha.
-
- Store login session information