Table of Contents
If you have already configured a working acl-setup but need http-auth-functionality for, say, the dokuwiki cli, you can set up http-auth-passthru like this:
Open the .htaccess in Dokuwiki's root in your favourite editor and add the following lines to it:
AuthType Basic AuthName "DokuWiki"
That's all. Don't set a “require valid-user” or something.
(You can use the local.php, too, but to be safe from the configuration plugin, please do use the local.protected.php!)
Go into your conf-directory and edit (or add) the file “local.protected.php” and add this line:
if (isset($_SERVER['PHP_AUTH_USER']) and !isset($_SESSION[$conf['title']]['auth']['info'])) $_REQUEST['u'] = $_SERVER['PHP_AUTH_USER'];
(Thanks to this page)
Remember to put a “<?php” at the beginning and an “?>” at the end, if the local.protected.php was empty before.
That's all you need. Now, HTTP-Auth can be used to authenticate against dokuwiki.