Extension:OAuth2 Client

The OAuth2 Client extension allows your users the ability to login to your wiki using any third-party site supporting OAuth2, like Google, Facebook, GitHub, SoundCloud.

This extension uses the PHP's League's OAuth 2.0 Client library.

Installation
The following instructions require Composer to install. cd extensions git clone https://github.com/Schine/MW-OAuth2Client.git

cd MW-OAuth2Client git submodule update --init
 * Fetch OAuth2 Client submodule:

cd vendors/oauth2-client composer install
 * Install submodule with composer:

wfLoadExtension( 'MW-OAuth2Client' );
 * Add the following code to the bottom of your LocalSettings.php:

✅ - Navigate to Special:Version on your wiki to verify that the extension is successfully installed.

Configuration parameters
Required settings to be added to LocalSettings.php

The Redirect URI for your wiki should be: http://your.wiki.domain/path/to/wiki/Special:OAuth2Client/callback

Optional further configuration

Popup Window
To use a popup window to login to the external OAuth2 server, copy the JS from modal.js to the MediaWiki:Common.js page on your wiki.