This is an OAuth provider for Azure Active Directory. It is supposed to be used with Social plugin from Dukt
This plugin requires Craft CMS 3.0.0-beta.23 or later.
To install the plugin, follow these instructions.
-
Open your terminal and go to your Craft project:
cd /path/to/project
-
Add Github repo to your
composer.json
"repositories": [ { "type":"git", "url":"https://github.com/simple-integrated-marketing/azure-active-directory-oauth.git" } ]
-
Then tell Composer to load the plugin:
composer require "simpleteam/azure-active-directory-oauth:dev-master"
-
In the Control Panel, go to Settings → Plugins and click the “Install” button for Azure Active Directory OAuth.
This plugin adds Microsoft Azure Active Directory Provider to the Social plugin by Dukt.
You will need to config the provider the same way you do with some native providers in Social Plugin.
config/social.php
<?php
return [
'allowEmailMatch' => true,
'lockDomains' => [],
'enableCpLogin' => true,
'loginProviders' => [
"azureactivedirectory" => [
"oauth" => [
'options' => [
"clientId" => "CLIENT_ID",
"clientSecret" => "CLIENT_SECRET",
]
],
'userFieldMapping' => [
'id' => "{{ profile.id }}",
'email'=>"{{ profile.email }}",
'username'=>"{{ profile.email }}",
'firstName'=> "{{ profile.givenName }}"
],
]
]
];
Brought to you by Simple Integrated Marketing