ACL Management doesn't work

Bug #589469 reported by stulpi
20
This bug affects 3 people
Affects Status Importance Assigned to Milestone
dokuwiki (Debian)
Fix Released
Unknown
dokuwiki (Ubuntu)
Fix Released
Undecided
Tanguy Ortolo

Bug Description

Binary package hint: dokuwiki

When trying to use the web based acl management of dokuwiki, nothing happens. Apache2 error log says:
PHP Fatal error: require_once(): Failed opening required '/var/lib/dokuwiki/plugins/acl/../../../inc/init.php' (include_path='.:/usr/share/php:/usr/share/pear') in /var/lib/dokuwiki/plugins/acl/ajax.php on line 15, referer: http://XXXX.XX/dokuwiki/doku.php?id=addressbook&do=admin&page=acl

System:
Ubuntu 10.04 LTS with all updates
dokuwiki 0.0.20091225c-3
apache2 2.2.14-5ubuntu8

Of course, $conf['useacl'] = 1; is set in /etc/dokuwiki/local.php

ProblemType: Bug
DistroRelease: Ubuntu 10.04
Package: dokuwiki 0.0.20091225c-3
ProcVersionSignature: Ubuntu 2.6.32-22.35-generic 2.6.32.11+drm33.2
Uname: Linux 2.6.32-22-generic x86_64
NonfreeKernelModules: nvidia
Architecture: amd64
Date: Fri Jun 4 02:47:02 2010
InstallationMedia: Ubuntu 9.10 "Karmic Koala" - Release amd64 (20091027)
PackageArchitecture: all
ProcEnviron:
 LANG=en_US.UTF-8
 SHELL=/bin/bash
SourcePackage: dokuwiki

Revision history for this message
stulpi (muell1-stulpi) wrote :
Revision history for this message
knesek (knesek) wrote :

I have the same problem.

The problem is in the php script /var/lib/dokuwiki/plugins/acl/ajax.php (acl plugin)

In the following line

if(!defined('DOKU_INC')) define('DOKU_INC',dirname(__FILE__).'/../../../');

ajax.php defines path to 'DOKU_INC' wrongly (DOKU_INC is not defined at this point).
DOKU_INC is not located at /var/lib/dokuwiki/plugins/acl/../../../ where ajax.php searches for it.

In the ubunut installed dokuwiki, inc directory is located at /usr/share/dokuwiki/

It is possible to temporarily work around this problem by modifing ajax.php
(first make a backup copy of ajax.php, just in case something goes wrong)

Replace the line

if(!defined('DOKU_INC')) define('DOKU_INC',dirname(__FILE__).'/../../../');

with

if(!defined('DOKU_INC')) define('DOKU_INC','/usr/share/dokuwiki/');

Revision history for this message
knesek (knesek) wrote :

lines were wrapped in the comment so I'm attaching the modified ajax.php that works for me (it has /usr/share/dokuwiki/ hardcoded - not optimal solution, but works for me).

Revision history for this message
stulpi (muell1-stulpi) wrote :

Thanks!

This solution works for me too.

Revision history for this message
Tanguy Ortolo (tanguy+ubuntu) wrote :

Hello,

This bug was also reported on the Debian Bug Tracking System: <http://bugs.debian.org/588405>.

I am trying to find the best solution, and I shall upload an updated package when I am done.

Changed in dokuwiki (Ubuntu):
assignee: nobody → Tanguy Ortolo (tanguy+ubuntu)
status: New → In Progress
Revision history for this message
Launchpad Janitor (janitor) wrote :
Download full text (5.8 KiB)

This bug was fixed in the package dokuwiki - 0.0.20091225c-8

---------------
dokuwiki (0.0.20091225c-8) unstable; urgency=low

  * debian/rules: remove lib/exe/multipleUpload.swf from binary package, as it
    cannot be built from source, violating the Policy. (Closes: #592593)
  * debian/NEWS: document that removal and how to get
    lib/exe/multipleUpload.swf from the upstream distribution.
  * debian/postinst: correct wrong plugin path
     + in the dpkg-statoverride. (Closes: #592653)
     + in the symlink creation. (Closes: #592656)
  * debian/po/de.po: debconf template translation update
     + German, thanks to Holger Wansing. (Closes: #592651)
  * debian/copyright: explicited the license of lib/_fla/* (the Flash-base
    multiple upload applet).

dokuwiki (0.0.20091225c-7) unstable; urgency=low

  * debian/po/fr.po: debconf template translation update
     + French, thanks to Steve Petruzzello. (Closes: #591252)
  * debian/control: bumped Standards-Version to 3.9.1 (no change
    needed).

dokuwiki (0.0.20091225c-6) unstable; urgency=low

  * debian/postinst: check existence of conffiles before chown/chmoding them:
    the user may have deleted them. (Closes: #589263)
  * debian/po/*.po: debconf templates translation update
     + Czech, thanks to Miroslav Kure. (Closes: #589566)
     + Danish (new translation), thanks to Joe Hansen. (Closes: #589095)
     + Spanish, thanks to Francisco Javier Cuadrado. (Closes: #590051)
     + Portuguese, thanks to Rui Branco. (Closes: #589086)
     + Russian, thanks to Yuri Kozlov. (Closes: #588950)

dokuwiki (0.0.20091225c-5) unstable; urgency=low

  * debian/preinst: remove useless ucf association with
    /usr/share/dokuwiki/.htaccess
  * debian/postinst:
     + make /etc/dokuwiki/local.php readable by the web server.
       (Closes: #588699)
     + transition to plugins and templates under /var/lib/dokuwiki/lib,
       see below.
     + remove auto_prepend_file from Apache configuration: it only works
       with mod_php and is now useless, see below.
     + generate wiki configuration file /etc/dokuwiki/local.php candidate
       event if there is already one: ucf is here to allow the user to manage
       the conflict.
  * debian/postrm: do not call lighty-disable-mod if lighttpd is not
    installed. (Closes: #588700)
  * debian/copyright: integrated the BSD license, as it will be removed from
    common-licenses.
  * debian/control: updated Standards-Version to 3.9.0, taking into account
    the BSD license removal from common-licenses.
  * debian/patches/fhs.diff: modified lib/plugins/acl/ajax.php to define
    DOKU_INC to its location under Debian. (Closes: #588405) (LP: #589469)
  * Added an ucf historical md5sum file for
    /usr/share/dokuwiki/.htaccess.dist.
  * conf/license.php: backported an upstream commit to fix the CC-BY-ND
    license URL (btw, this license is inappropriate for a wiki, and will be
    removed in the next upstream version). (Closes: #531353)
  * Added a lintian override for a template detected as unused because
    lintian does not understand Perl config scripts.
  * Moved templates and plugins to /var/lib/dokuwiki/lib, to reproduce the
    original hierarchy of ...

Read more...

Changed in dokuwiki (Ubuntu):
status: In Progress → Fix Released
Changed in dokuwiki (Debian):
status: Unknown → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.