# AllianceAuth Wiki integration

**URL:** <https://forums.eveonline.com/t/allianceauth-wiki-integration/146410>\
**Category:** Third Party Developers\
**Tags:** esi, tool\
**Created:** [March 15, 2019, 10:12pm UTC](https://forums.eveonline.com/t/allianceauth-wiki-integration/146410 "2019-03-15T22:12:40Z")\
**Posts on this page:** 10\
**Page:** 1

<div class="post-metadata">

**Author:** ![4tt1c](https://sea1.discourse-cdn.com/eveonline/user_avatar/forums.eveonline.com/4tt1c/32/294747_2.png) [@4tt1c](https://forums.eveonline.com/u/4tt1c)\
**Post date:** [March 15, 2019, 10:12pm UTC](https://forums.eveonline.com/t/allianceauth-wiki-integration/146410/1 "2019-03-15T22:12:40Z")

</div>

Hello everyone,

currently i’m trying to integrate dokuWiki into our AllianceAuth.

With a little help from Google I’ve found [this](https://github.com/kormat/aauth-dokuwiki) module, which makes the Wiki availible to the authenticated users. But I’m facing some troubles:

1. On the “Services” page of AllianceAuth the Wiki only shows up, when I’m logged in with my admin account. Normal users, even with granted Wiki access, can’t see the link to the Wiki within “Services”.

2. I can’t figure out how to “teach” dokuWiki to only accept loggins via AllianceAuth. The module linked above referrs to [this module](https://github.com/pcd1193182/dokuwiki-discourse-sso) as the corresponding one for dokuWiki, but after integration my Wiki wasn’t accessible any more.

So, is there anyone who had the same issues and found a solution or can someone maybe help me with the installation. I think an extended installation documentation would also help.

Thanks in advance,  
4tt1c

---

<div class="post-metadata">

**Author:** ![4tt1c](https://sea1.discourse-cdn.com/eveonline/user_avatar/forums.eveonline.com/4tt1c/32/294747_2.png) [@4tt1c](https://forums.eveonline.com/u/4tt1c)\
**Post date:** [March 16, 2019, 6:10pm UTC](https://forums.eveonline.com/t/allianceauth-wiki-integration/146410/2 "2019-03-16T18:10:08Z")

</div>

Hello again,

a little update:  
I’ve managed to implement both modules but the Wiki site now shows “cleanup session failed”. Nothing more.  
Does anyone know how to handle or what is meant by this?

---

<div class="post-metadata">

**Author:** ![Petty\_Thief](https://sea1.discourse-cdn.com/eveonline/user_avatar/forums.eveonline.com/petty_thief/32/367736_2.png) [@Petty\_Thief](https://forums.eveonline.com/u/Petty_Thief)\
**Post date:** [March 17, 2019, 10:20am UTC](https://forums.eveonline.com/t/allianceauth-wiki-integration/146410/3 "2019-03-17T10:20:54Z")

</div>

Enable debug within Dokuwiki and see what the log says. From the error i assume is something related to the SSO from AAuth via discourse SSO plugin and then to dokuwiki

---

<div class="post-metadata">

**Author:** ![4tt1c](https://sea1.discourse-cdn.com/eveonline/user_avatar/forums.eveonline.com/4tt1c/32/294747_2.png) [@4tt1c](https://forums.eveonline.com/u/4tt1c)\
**Post date:** [March 17, 2019, 10:10pm UTC](https://forums.eveonline.com/t/allianceauth-wiki-integration/146410/4 "2019-03-17T22:10:26Z")

</div>

Thanks for this hint Petty Thief.

After some investigation i’ve found a SQL statement that can not be executed properly.

The statement

**SELECT id FROM session WHERE sessionid = :sessionid;**

gives back

**ERROR 1064 (42000): You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near ‘:sessionid’ at line 1**

but i can’t figure out what’s wrong with this statement.  
I’m using MySQL 5.7.25-0ubuntu0.16.04.2, is there any restriction in the syntax between different versions of MySQL? Maybe the statement only works with older versions?

---

<div class="post-metadata">

**Author:** ![Petty\_Thief](https://sea1.discourse-cdn.com/eveonline/user_avatar/forums.eveonline.com/petty_thief/32/367736_2.png) [@Petty\_Thief](https://forums.eveonline.com/u/Petty_Thief)\
**Post date:** [March 18, 2019, 10:40am UTC](https://forums.eveonline.com/t/allianceauth-wiki-integration/146410/5 "2019-03-18T10:40:52Z")

</div>

> [@4tt1c](#):
>
> :sessionid

**:sessionid** should be a variable, but it’s passed incorrectly to the SQL statement. try to find out in which file this piece of code is and see from there if this needs escaped try adding some ’ and ’ between first.

**SELECT id FROM session WHERE sessionid = ‘:sessionid’;**

---

<div class="post-metadata">

**Author:** ![4tt1c](https://sea1.discourse-cdn.com/eveonline/user_avatar/forums.eveonline.com/4tt1c/32/294747_2.png) [@4tt1c](https://forums.eveonline.com/u/4tt1c)\
**Post date:** [March 21, 2019, 6:52pm UTC](https://forums.eveonline.com/t/allianceauth-wiki-integration/146410/6 "2019-03-21T18:52:40Z")

</div>

Hey,

sorry for the delay, i was not in town.  
I’ve fixed the statement problem with choosing the correct database table in the config file.

Now AllianceAuth redirects me correctly to the wiki, but the login button doesn’t show up.  
So i see the start page that tells me i would have not enough permissions, which is correct.  
If i click on the wiki-login button a blank wiki page shows up and i can do nothing.

I expected to see the same login button as it is used within alliance auth

EDIT:  
After a look into the Nginx error.log i found this one:

2019/03/21 22:02:06 [error] 26732#26732: \*41 FastCGI sent in stderr: “PHP message: PHP Fatal error: Uncaught Error: Class ‘Ramsey\Uuid\Uuid’ not found in /var/www/dokuwiki/lib/plugins/discoursesso/sso\_nonce.php:55  
Stack trace:  
#0 /var/www/dokuwiki/inc/html.php(47): gen\_nonce(‘start’)  
#1 /var/www/dokuwiki/inc/Action/Login.php(33): html\_login()  
#2 /var/www/dokuwiki/inc/template.php(98): dokuwiki\Action\Login-\>tplContent()  
#3 /var/www/dokuwiki/inc/events.php(111): tpl\_content\_core(‘login’)  
#4 /var/www/dokuwiki/inc/events.php(256): Doku\_Event-\>trigger(‘tpl\_content\_cor…’, true)  
#5 /var/www/dokuwiki/inc/template.php(83): trigger\_event(‘TPL\_ACT\_RENDER’, ‘login’, ‘tpl\_content\_cor…’)  
#6 /var/www/dokuwiki/lib/tpl/dokuwiki/main.php(59): tpl\_content()  
#7 /var/www/dokuwiki/inc/actions.php(27): include(’/var/www/dokuwi…’)  
#8 /var/www/dokuwiki/doku.php(120): act\_dispatch()  
#9 {main}  
thrown in /var/www/dokuwiki/lib/plugins/discoursesso/sso\_nonce.php on line 55” while reading upstream, client: THIS.IS.MY.IP, server: , request: “GET /doku.php?id=start&do=login&sectok= HTTP/1.1”, upstream: “fastcgi://unix:/run/php/php7.0-fpm.sock:”, host: “[www.thisismywebsite.com](http://www.thisismywebsite.com)”, referrer: “[http://www.thisismywebsite.com/doku.php?id=start](http://www.thisismywebsite.com/doku.php?id=start)”

Any hints?

---

<div class="post-metadata">

**Author:** ![Brock\_Khans](https://sea1.discourse-cdn.com/eveonline/user_avatar/forums.eveonline.com/brock_khans/32/409174_2.png) [@Brock\_Khans](https://forums.eveonline.com/u/Brock_Khans)\
**Post date:** [March 25, 2019, 5:05am UTC](https://forums.eveonline.com/t/allianceauth-wiki-integration/146410/7 "2019-03-25T05:05:19Z")

</div>

> [@4tt1c](#):
>
> Fatal error: Uncaught Error: Class ‘Ramsey\Uuid\Uuid’ not found in /var/www/dokuwiki/lib/plugins/discoursesso/sso\_nonce.php:55

Seems a dependency isn’t installed

> **[GitHub - ramsey/uuid: :snowflake: A PHP library for generating universally...](https://github.com/ramsey/uuid)**
>
> :snowflake: A PHP library for generating universally unique identifiers (UUIDs). - GitHub - ramsey/uuid: :snowflake: A PHP library for generating universally unique identifiers (UUIDs).

---

<div class="post-metadata">

**Author:** ![4tt1c](https://sea1.discourse-cdn.com/eveonline/user_avatar/forums.eveonline.com/4tt1c/32/294747_2.png) [@4tt1c](https://forums.eveonline.com/u/4tt1c)\
**Post date:** [March 25, 2019, 12:43pm UTC](https://forums.eveonline.com/t/allianceauth-wiki-integration/146410/8 "2019-03-25T12:43:18Z")

</div>

Hey Brock,

thanks for your reply.

You’re right, there was a problem with the installation of ramsey/uuid, so i’ve installed it manually through a git download and composer install.

After that the error message still doesn’t change. I’m still getting the same error when trying to access the login page.

---

<div class="post-metadata">

**Author:** ![Brock\_Khans](https://sea1.discourse-cdn.com/eveonline/user_avatar/forums.eveonline.com/brock_khans/32/409174_2.png) [@Brock\_Khans](https://forums.eveonline.com/u/Brock_Khans)\
**Post date:** [March 25, 2019, 6:57pm UTC](https://forums.eveonline.com/t/allianceauth-wiki-integration/146410/9 "2019-03-25T18:57:19Z")

</div>

well I’d check to see why it didn’t install with teh dokuwiki thing, its looking for a very specific location/class that may be different if you manually install it.

---

<div class="post-metadata">

**Author:** ![system](https://global.discourse-cdn.com/eveonline/original/3X/4/1/41ec4921cbaca7a6f9ea556e7cc20018461eae5e.png) [@system](https://forums.eveonline.com/u/system)\
**Post date:** [June 23, 2019, 6:57pm UTC](https://forums.eveonline.com/t/allianceauth-wiki-integration/146410/10 "2019-06-23T18:57:21Z")

</div>

Closed on June 23, 2019, 6:57pm UTC

This topic was automatically closed 90 days after the last reply. New replies are no longer allowed.
