My company uses WordPress and MediaWiki internally, and we use HTTP_AUTH access control to create single sign-on. As additional applications are added, we simply integrate them into the HTTP_AUTH system, where it is practically possible. For security, you can run HTTP_AUTH over SSL. The main steps:
Configure .htaccess to specify the type of authentication. We use MySQL in production, but you may have a simple htpasswd file.
In the .htaccess directory of the WordPress directory, add the following:
<Files wp-login.php>
AuthType Basic
AuthName "Restricted Access"
AuthUserFile / some / path / to / htpasswd
Require valid-user
</Files>
In WordPress wp-admin / directory.htaccess add the following:
AuthType Basic
AuthName "Restricted Access"
AuthUserFile / some / path / to / htpasswd
Require valid-user
In the MediaWiki.htaccess file, add the following:
AuthType Basic
AuthName "Restricted Access"
AuthUserFile / some / path / to / htpasswd
Then install the HttpAuth extension for MediaWiki and HTTP Authentication for WordPress and setup. We had to make some changes to the MediaWiki extension, since our hosting environment does not provide mod_php, but if you have mod_php, it will work out of the box.
Please note that our environment is a private intranet, therefore all are authenticated. The above .htaccess files will work for public blogs, but MediaWiki.htaccess may require additional configuration depending on whether you want everyone to be required for authentication or not, and if the site is public.
Michael ridge
source share