docs/main/administration-guide/onboard/sso-entraid.mdx
Follow these steps to configure Mattermost to use your Entra ID logon credentials and Azure Active Directory account as a Single Sign-on (SSO) service for team creation, account creation, and sign-in.
/signup/office365/complete. An example below is: https://your.mattermost.com/signup/office365/completeOnce the App Registration has been created, you can configure it further. See the standard Azure AD documentation for reference.
https://login.microsoftonline.com/common/v2.0/.well-known/openid-configuration.When Mattermost is configured to use OpenID Connect or OAuth 2.0 for user authentication, the following user attribute changes can't be made through the Mattermost API: first name, last name, or username. OpenID Connect or OAuth 2.0 must be the authoritative source for these user attributes.
</Note>A Microsoft Active Directory (AD) tenant is a dedicated instance of Azure Active Directory (Azure AD) that you own and would have received when signing up for a Microsoft cloud service, such as Azure or Entra ID. Tenants are commonly used by organizations who want to store information about their users, such as passwords, user profile data, and permissions. See the Microsoft Entra ID documentation to learn more about getting an Azure AD tenant.
To allow your Azure AD users to log in to Mattermost using Entra ID SSO, you must register Mattermost in the Microsoft Azure AD tenant that contains the users' information. The registration can be done from the Microsoft Azure portal. The steps to register the Mattermost account in the tenant should be similar to those provided above, and you can find more information about integrating apps with Azure AD here.
If you don't register Mattermost in the Microsoft Azure AD tenant your organization uses, Entra ID SSO will likely fail for your users.
<Note>If you do not use Azure Active Directory, you may register Mattermost with your Entra ID or Azure account (a personal, work, or school account), then set up Entra ID SSO with Mattermost using the steps provided above.
</Note>config.json for Entra ID SSOInstead of using the System Console, you can add the Entra ID settings directly to the config.json file on your Mattermost server.
config.json as root in a text editor. It’s usually in /opt/mattermost/config but it might be elsewhere on your system.Office365Settings section, then add or update the following information:"Office365Settings": {
"Enable": false,
"Secret": "i.hddd6Pu3--5dg~cRddddqOrBdd1a",
"Id": "28ddd714-1f2f-4f9c-9486-90b8dddd27",
"Scope": "profile openid email",
"AuthEndpoint": "",
"TokenEndpoint": "",
"UserApiEndpoint": "",
"DiscoveryEndpoint": "https://login.microsoftonline.com/common/v2.0/.well-known/openid-configuration",
"DirectoryId": "common"
}
At this time, LDAP data isn't compatible with OpenID. If you currently rely on LDAP to manage your users' teams, channels, groups, or attributes, you won't be able to do this automatically with users who have logged in with OpenID. If you need LDAP synced to each user, we suggest using SAML or LDAP as the login provider. Some OpenID providers can use SAML instead, like Keycloak.