Bug 20780

Summary: dokuwiki can't login, due to missing vendor library
Product: Mageia Reporter: Glen Ogilvie <nelg>
Component: RPM PackagesAssignee: All Packagers <pkg-bugs>
Status: NEW --- QA Contact:
Severity: normal    
Priority: Normal    
Version: Cauldron   
Target Milestone: ---   
Hardware: All   
OS: Linux   
Whiteboard:
Source RPM: dokuwiki-20170219-3.mga6.src.rpm CVE:
Status comment:

Description Glen Ogilvie 2017-05-04 05:12:32 CEST
Description of problem:
When trying to login to the web interface of dokuwiki, we get:

[Thu May 04 15:02:41.650886 2017] [:error] [pid 20315] [client 127.0.0.1:49988] PHP Fatal error:  Call to undefined function random_bytes() in /usr/share/dokuwiki/inc/auth.php on line 333, referer: http://localhost/dokuwiki/doku.php?id=start&do=login&sectok=

This function, is included in php7, but also provided in the vendor libs.
For some reason, the vendor libs are not included in the spec file.

How reproducible:
100%

Steps to Reproduce:
1. Install dokuwiki on Mageia 6 with apache.
2. Create a user and try to login


Making the following change to the spec file will fix the problem:


Index: dokuwiki.spec
===================================================================
--- dokuwiki.spec       (revision 1098973)
+++ dokuwiki.spec       (working copy)
@@ -93,8 +93,7 @@
 
 # missing composer file
 mkdir -p %{buildroot}/%{_datadir}/%{name}/vendor
-touch %{buildroot}/%{_datadir}/%{name}/vendor/autoload.php
-
+cp -pr vendor/* %{buildroot}%{_datadir}/%{name}/vendor/
 
 %pre
 if [ $1 = "2" ]; then
Comment 1 Glen Ogilvie 2017-05-04 05:13:38 CEST
We need this because Mageia 6 ships with PHP 5.6.30
Rémi Verschelde 2017-05-04 07:39:45 CEST

Assignee: bugsquad => tarakbumba
Summary: Can't login, due to missing vendor library => dokuwiki can't login, due to missing vendor library

Comment 2 Atilla ÖNTAŞ 2017-05-30 02:16:35 CEST
Thank you for reporting. I have submmitted dokuwiki-20170219-4.mga6 which uses build-in vendor libs until we start to use php7. Please test and feedback when it hits repos.
Comment 3 Samuel Verschelde 2018-09-21 09:40:21 CEST
Reassigning to all packagers collectively as the original maintainer is not available anymore (thanks for all your work Atilla!).

Assignee: tarakbumba => pkg-bugs