I know this is probably kind of a niche question, but I'm a little stumped here.
I've set up wiki farms with older versions of DokuWiki and I've set up Shibboleth-based logins (with
Ivan Novakov's authshibboleth plugin), but I'm running into problems combining them.
I'm using the DokuWIki RPM for RHEL 6 in EPEL. It's for Binky, 2013-12-08. It installs the PHP code into /usr/share/dokuwiki, the configuration files into /etc/dokuwiki, and the data tree into /var/lib/dokuwiki. I have added the authshibboleth plugin and can log in to the main wiki, view and edit pages, and so on.
I'm trying to set up a farm configuration. I've edited /usr/share/dokuwiki/inc/preload.php and added the following lines:
[indent]
if(!defined('DOKU_FARMDIR')) define('DOKU_FARMDIR', '/var/www/dokuwiki');
include(fullpath(dirname(__FILE__)).'/farm.php');
[/indent]
I then have a test wiki using the ".htaccess" farm configuration. My Apache docroot is /var/www/html, so I have a directory named /var/www/html/testwiki that contains a .htaccess file with the following contents:
[indent]
RewriteEngine on
RewriteRule ^(.*) /dokuwiki/$1?animal=testwiki [QSA]
RewriteRule ^(index.html)?$ /dokuwiki/?animal=testwiki [QSA]
[/indent]
So far, this works; I can visit
http://my.webserver.com/testwiki and get any pages that I manually add to the testwiki's data directory.
When I enable Shibboleth authentication for the animal (by putting "AuthType Shibboleth/Require Shibboleth" lines in the .htaccess file and enabling the authshibboleth authentication plugin) and click the "Login" link, I get directed to my IdP, log in, get redirected back to the wiki page, and then get immediately redirected to the Shibboleth logout page. If I trigger a Shibboleth login from another place on the website and then visit the farmer wiki, it correctly recognizes the existing login. If I instead go to the testwiki animal, it immediately sends me to the logout page.
I've looked through the authshibboleth code a bit. I don't see anything in there that would initiate logouts; it just catches the logOff message and handles that in a Shibboleth-appropriate way. That means that there's something in the main DokuWiki code deciding to log me out. I just can't figure out what.
So here are my questions: What might be going wrong here? I'm not that familiar with the DokuWIki codebase; where might I want to be looking to try and figure out why it seems to want to log me out when I visit the animal wiki? Is there anything that might help me to more easily debug whatever's going wrong here?