DokuWiki

It's better when it's simple

User Tools

Site Tools


plugin:authjoomla

AuthJoomla Plugin

Compatible with DokuWiki

Greebo

plugin

Last updated on
2018-05-07
Provides
Auth
Repository
Source

This extension has not been updated in over 2 years. It may no longer be maintained or supported and may have compatibility issues.

Tagged with joomla

This plugin allows authentication against a Joomla CMS user database with optional Single-Sign-On (SSO).

A CosmoCode Plugin

Installation

:!: Requirements:

  • a recent version of Joomla (tested with Joomla 3.8.7)
  • for Single-Sign-On:
    • sessions stored in the database 1)
    • Joomla and DokuWiki running on the same domain

Search and install the plugin using the Extension Manager. Refer to Plugins on how to install plugins manually.

Configuration

The plugin has a few config options:

  • debug – when enabled some more detailed error messages are displayed, helpful during setup
  • dsn – the connection string to access the Joomla data base. eg. mysql:host=localhost;dbname=joomla;charset=utf8
  • user – the user to access the Joomla database
  • pass – the password to access the Joomla database
  • tableprefix – the table prefix used for installing Joomla, should include the trailing underscore _
  • cookiename – optional cookie name to enable SSO, see below

Single Sign-On

When used without setting the cookiename option, this plugin simply preconfigures the authpdo plugin. You can login with your Joomla user/password credentials.

Once the cookie name is set, DokuWiki will check if this cookie exists, reads the Joomla session identifier from it and checks if a valid session exists in Joomla's session table. If so, the user is logged into DokuWiki automatically without the need to log in manually.

Please note: users logging into DokuWiki will not be logged into Joomla automatically.

The cookie name used by Joomla is a semi-random string. Easiest way to find it is using Chrome's Developer Tools:

  1. log into your Joomla in Chrome
  2. press F12 to open the developer Tools
  3. switch to the Application tab
  4. select Storage → Cookies → your URL from the sidebar
  5. You should see a Cookie with a 32 character hex name and another hex string as value
  6. The name is what you are looking for copy it into your DokuWiki configuration

Users and Groups

Users and Groups are named as they are in Joomla. No normalizing to DokuWiki page IDs is done. You will probably want to adjust your ACLs and super user settings.

Groups in Joomla are hierarchical. This is reflected in this Plugin. When a user is in one Joomla group, the user will also be in the upper groups in DokuWiki. A / is used as hierarchy separator.

Eg. the super user is by default in the following groups:

  • Public
  • Public/Super Users

In addition all users are automatically added to the configured default group.

See also

1)
Joomla Admin → System → Global Configuration → Session Settings → Session Handler: Database
plugin/authjoomla.txt · Last modified: 2024-01-08 16:49 by Aleksandr

Except where otherwise noted, content on this wiki is licensed under the following license: CC Attribution-Share Alike 4.0 International
CC Attribution-Share Alike 4.0 International Donate Powered by PHP Valid HTML5 Valid CSS Driven by DokuWiki