[omd-commits] OMD Git: omd: Dokuwiki: Fixed integration with multisite cookie authentication

git version control git at mathias-kettner.de
Wed Feb 19 10:09:17 CET 2014


Module:   omd
Branch:   master
Commit:   ca6930d5e0373ac2d7dafd70030472b768fac1c9
URL:      http://omdistro.org/projects/omd/repository/revisions/ca6930d5e0373ac2d7dafd70030472b768fac1c9

Author:   Lars Michelsen <lm at mathias-kettner.de>
Date:     Wed Feb 19 10:08:45 2014 +0100
Commiter: Lars Michelsen <lm at mathias-kettner.de>
Date:     Wed Feb 19 10:08:45 2014 +0100

Dokuwiki: Fixed integration with multisite cookie authentication

---

 Changelog                                    |    1 +
 packages/check_mk/MULTISITE_COOKIE_AUTH.hook |    2 +-
 packages/dokuwiki/authmultisite/auth.php     |    2 +-
 packages/dokuwiki/preload.php                |    2 +-
 4 files changed, 4 insertions(+), 3 deletions(-)

diff --git a/Changelog b/Changelog
index fa549ca..23ec6b7 100644
--- a/Changelog
+++ b/Changelog
@@ -15,6 +15,7 @@ This file documents the revision history for the Open Monitoring Distribution
               reload of the system apache instead of a restart
             - Added nagios/icinga reload init hooks
           - Check_MK/MK Livestatus: new version 1.2.4
+          - Dokuwiki: Fixed integration with multisite cookie authentication
 
 1.10     Dec 15 2013
           - omd: More friendly error messages when init scripts do not exist
diff --git a/packages/check_mk/MULTISITE_COOKIE_AUTH.hook b/packages/check_mk/MULTISITE_COOKIE_AUTH.hook
index 6e3baa3..9acb582 100755
--- a/packages/check_mk/MULTISITE_COOKIE_AUTH.hook
+++ b/packages/check_mk/MULTISITE_COOKIE_AUTH.hook
@@ -47,7 +47,7 @@ EOF
 // Created by OMD hook MULTISITE_COOKIE_AUTH
 //
 \$conf['useacl'] = 1;
-\$conf['authtype'] = 'multisite';
+\$conf['authtype'] = 'authmultisite';
 \$conf['superuser'] = '@admin';
 \$conf['multisite']['authfile'] = '/omd/sites/$OMD_SITE/var/check_mk/wato/auth/auth.php';
 \$conf['multisite']['auth_secret'] = '/omd/sites/$OMD_SITE/etc/auth.secret';
diff --git a/packages/dokuwiki/authmultisite/auth.php b/packages/dokuwiki/authmultisite/auth.php
index 7ecf0a7..58f1374 100644
--- a/packages/dokuwiki/authmultisite/auth.php
+++ b/packages/dokuwiki/authmultisite/auth.php
@@ -91,7 +91,7 @@ class auth_plugin_authmultisite extends DokuWiki_Auth_Plugin {
             continue;
         }
       }
-      header('Location:../check_mk/login.py?_origtarget=' . $_SERVER['REQUEST_URI']);
+      header('Location:../check_mk/login.py?_origtarget=' . urlencode($_SERVER['REQUEST_URI']));
       return false;
   }
 
diff --git a/packages/dokuwiki/preload.php b/packages/dokuwiki/preload.php
index 7143876..c15ddd2 100644
--- a/packages/dokuwiki/preload.php
+++ b/packages/dokuwiki/preload.php
@@ -16,7 +16,7 @@ if(substr($_SERVER["SCRIPT_FILENAME"], 0, 4) == '/omd') {
 $config_cascade = array(
     'main' => array(
         'default'   => array(DOKU_CONF.'dokuwiki.php'),
-        'local'     => array(DOKU_CONF.'local.php'),
+        'local'     => array(DOKU_CONF.'local.php', DOKU_CONF.'cookie_auth.php'),
         'protected' => array(DOKU_CONF.'local.protected.php'),
     ),
     'acronyms'  => array(



More information about the omd-commits mailing list