Modern Authentication (OAuth2) as Email Authentication Method with O365
Modern Authentication (OAuth2) as Email Authentication Method with O365
Note:
Configuring ESM to use O365 (Exchange Online) has some limitations with emails that can have affect to ESM's operation if not taken into account.
- Only IMAP and SMTP can be used with OAuth2 in ESM
- Authenticated SMTP limits outgoing emails to 30 messages per minute / 10,000 recipients per day (https://docs.microsoft.com/en-us/exchange/troubleshoot/send-emails/smtp-submission-improvements)
To configure modern authentication (OAuth2) instead basic authentication for the SMTP and IMAP protocols in ESM, we need to do three steps:
- ESM needs to be registered as an approved application in the Azure Active Directory through Microsoft Azure portal.
- The registered application needs to be granted access for the O365 mailbox account used for Efecte.
- ESM platform settings need to be updated to be in sync with the Microsoft Azure settings.
To set up ESM platform settings, please go to ESM admin view > Platform Settings > Mail Settings section and set the following properties:mail.oauth.enabled = truemail.oauth.authorize.endpoint = https://login.microsoftonline.com/{tenantID}/oauth2/v2.0/authorizemail.oauth.client.id = {clientId}mail.oauth.scopes = https://outlook.office365.com/IMAP.AccessAsUser.All,https://outlook.office365.com/SMTP.Send
The clientId and authorize endpoint can be found from the Azure Active Directory frontpage for the application registered for ESM.
Detailed instructions for setting up the Azure can be found from Efecte Community and from this article.
Table of Contents