[Splashy-devel] dokuwiki patched

Luis Mondesi lemsx1 at gmail.com
Wed Jan 7 05:29:30 UTC 2009


I modified the wiki code to allow users to be managed from the admin
section of the web page. This is the patched I used (the wiki
directory is now managed with git):
(yes I hate hacks like this too but we need to comply with alioth's
admins policies of not allowing files visible from the web to be
writeable)

diff --git a/inc/auth/plain.class.php b/inc/auth/plain.class.php
index 02175d9..5c03c13 100644
--- a/inc/auth/plain.class.php
+++ b/inc/auth/plain.class.php
@@ -10,7 +10,7 @@
 define('DOKU_AUTH', dirname(__FILE__));
 require_once(DOKU_AUTH.'/basic.class.php');

-define('AUTH_USERFILE',DOKU_CONF.'users.auth.php');
+define('AUTH_USERFILE',$conf['savedir'].'/users.auth.php');

 // we only accept page ids for auth_plain
 if(isset($_REQUEST['u']))
diff --git a/inc/infoutils.php b/inc/infoutils.php
index 1fc5570..f35d2dd 100644
--- a/inc/infoutils.php
+++ b/inc/infoutils.php
@@ -157,10 +157,10 @@ function check(){
   }

   if($conf['authtype'] == 'plain'){
-    if(is_writable(DOKU_CONF.'users.auth.php')){
-      msg('conf/users.auth.php is writable',1);
+    if(is_writable($conf['savedir'].'/users.auth.php')){
+      msg($conf['savedir'].'/users.auth.php is writable',1);
     }else{
-      msg('conf/users.auth.php is not writable',0);
+      msg($conf['savedir'].'/users.auth.php is not writable',0);
     }
   }

-- 
----)(-----
Luis Mondesi
Maestro Debiano

----- START ENCRYPTED BLOCK (Triple-ROT13) ------
Gur Hohagh [Yvahk] qvfgevohgvba oevatf gur fcvevg bs Hohagh gb gur
fbsgjner jbeyq.
----- END ENCRYPTED BLOCK (Triple-ROT13) ------



More information about the Splashy-devel mailing list