From ca8ae96f9821890bf50b820bcc98d123cc6b6c7d Mon Sep 17 00:00:00 2001
From: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Date: Tue, 9 Dec 2014 13:48:29 +0000
Subject: [PATCH] [PASSED QA] Bug - 5511 [Followup]: Switched defults

Agree with Chris that the defualt should maintain the higher security
and not reduce it.

Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Chris Cormack <chrisc@catalyst.net.nz>

Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
---
 installer/data/mysql/sysprefs.sql                                    | 2 +-
 installer/data/mysql/updatedatabase.pl                               | 2 +-
 koha-tmpl/intranet-tmpl/prog/en/modules/admin/preferences/admin.pref | 2 +-
 3 files changed, 3 insertions(+), 3 deletions(-)

diff --git a/installer/data/mysql/sysprefs.sql b/installer/data/mysql/sysprefs.sql
index 36fa5ac..f6efb5a 100644
--- a/installer/data/mysql/sysprefs.sql
+++ b/installer/data/mysql/sysprefs.sql
@@ -473,5 +473,5 @@ INSERT INTO systempreferences ( `variable`, `value`, `options`, `explanation`, `
 ('XSLTResultsDisplay','default','','Enable XSL stylesheet control over results page display on intranet','Free'),
 ('z3950AuthorAuthFields','701,702,700',NULL,'Define the MARC biblio fields for Personal Name Authorities to fill biblio.author','free'),
 ('z3950NormalizeAuthor','0','','If ON, Personal Name Authorities will replace authors in biblio.author','YesNo'),
-('SessionRestrictionByIP','0','Check for Change in Remote IP address for Session Security . Disable when remote ip address changes frequently.','','YesNo');
+('SessionRestrictionByIP','1','Check for Change in Remote IP address for Session Security . Disable when remote ip address changes frequently.','','YesNo');
 ;
diff --git a/installer/data/mysql/updatedatabase.pl b/installer/data/mysql/updatedatabase.pl
index 0b5c390..454f691 100755
--- a/installer/data/mysql/updatedatabase.pl
+++ b/installer/data/mysql/updatedatabase.pl
@@ -9580,7 +9580,7 @@ if ( CheckVersion($DBversion) ) {
 
 $DBversion = "3.18.00.001";
 if ( CheckVersion($DBversion) ) {
-    $dbh->do("INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('SessionRestrictionByIP','0','Check for Change in  Remote IP address for Session Security. Disable when remote ip address changes frequently.','','YesNo')");
+    $dbh->do("INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES('SessionRestrictionByIP','1','Check for Change in  Remote IP address for Session Security. Disable when remote ip address changes frequently.','','YesNo')");
     print "Upgrade to $DBversion done (Bug 5511 - SessionRestrictionByIP)";
     SetVersion ($DBversion);
 }
diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/admin/preferences/admin.pref b/koha-tmpl/intranet-tmpl/prog/en/modules/admin/preferences/admin.pref
index e2ea915..6147ef7 100644
--- a/koha-tmpl/intranet-tmpl/prog/en/modules/admin/preferences/admin.pref
+++ b/koha-tmpl/intranet-tmpl/prog/en/modules/admin/preferences/admin.pref
@@ -65,7 +65,7 @@ Administration:
             - 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
+              default: 1
               choices:
                   yes: Enable
                   no: "Disable"
-- 
1.9.1