Some checks failed
Server CI / Postgres (shard 0) (push) Has been skipped
Server CI / Postgres (shard 3) (push) Has been skipped
BuildEnv Docker Image / build-image (push) Failing after 4s
BuildEnv Docker Image / build-image-fips (push) Failing after 4s
Migration Review & Release Notes / Generate migration review & release notes (push) Failing after 3s
Server CI / Build Environment (push) Failing after 3s
Server CI / Postgres (shard 1) (push) Has been skipped
Tools CI / check-style (mattermost-govet) (push) Failing after 4s
Server CI / Postgres (shard 2) (push) Has been skipped
Tools CI / check-style (mmgotool) (push) Failing after 3s
Server CI / Elasticsearch v8 Compatibility (push) Has been skipped
Server CI / OpenSearch v2 Compatibility (push) Has been skipped
Server CI / Postgres FIPS (shard 0) (push) Has been skipped
Tools CI / Test (mattermost-govet) (push) Failing after 3s
Server CI / Postgres FIPS (shard 1) (push) Has been skipped
Server CI / Postgres FIPS (shard 2) (push) Has been skipped
Tools CI / Test (mmgotool) (push) Failing after 3s
Server CI / Postgres FIPS (shard 3) (push) Has been skipped
Server CI / Run mmctl tests (push) Has been skipped
Server CI / Run mmctl tests (FIPS) (push) Has been skipped
Server CI / Merge Postgres Test Results (push) Has been skipped
Server CI / Merge Postgres FIPS Test Results (push) Has been skipped
Server CI / Check backport migrations (push) Has been skipped
Server CI / Check generated files (push) Has been skipped
Server CI / check-style (push) Has been skipped
Server CI / Vet API (push) Has been skipped
Server CI / Build mattermost server app (push) Has been skipped
Server CI / Server CI Complete (push) Failing after 2s
Server CI / Server CI Artifacts (push) Has been skipped
Server CI / Sentry Upload (push) Has been skipped
Server CI / Server CI Report (push) Failing after 5m1s
Server CI Nightly Race / Race Detector (push) Has been skipped
CodeQL / Analyze (go) (push) Has been cancelled
CodeQL / Analyze (javascript) (push) Has been cancelled
Webapp CI Cache Warm / Warm Webapp node_modules Cache (push) Has been cancelled
E2E CI Cache Warm / Warm E2E npm Registry Cache (push) Has been cancelled
API / build (push) Has been cancelled
Web App CI / check-types (push) Has been cancelled
Web App CI / check-lint (push) Has been cancelled
Web App CI / check-i18n (push) Has been cancelled
Web App CI / check-external-links (push) Has been cancelled
Web App CI / test (platform) (push) Has been cancelled
Web App CI / test (mattermost-redux) (push) Has been cancelled
Web App CI / test (channels shard 1/4) (push) Has been cancelled
Web App CI / test (channels shard 2/4) (push) Has been cancelled
Web App CI / test (channels shard 3/4) (push) Has been cancelled
Web App CI / test (channels shard 4/4) (push) Has been cancelled
Web App CI / upload-coverage (push) Has been cancelled
Web App CI / build (push) Has been cancelled
YAML Lint / yamllint (push) Has been cancelled
Push mirrored docker images / cd/Push mirrored docker images (push) Has been cancelled
docs-cd / Build and deploy docs (push) Has been cancelled
Docs CI / build (push) Has been cancelled
E2E Cache Warm: Cypress deps / Warm Cypress deps cache (push) Has been cancelled
Scorecards supply-chain security / Scorecard analysis (push) Has been cancelled
Server CI Weekly / Postgres FIPS (push) Has been skipped
Server CI Weekly / Run mmctl tests (FIPS) (push) Has been skipped
Server CI Weekly / Postgres with binary parameters (push) Has been skipped
Server CI Weekly / Build Environment (push) Failing after 1s
Server CI Cache Warm / Warm Go Module and Build Cache (push) Failing after 2s
Server CI Nightly Race / Build Environment (push) Failing after 1s
127 lines
8.8 KiB
Plaintext
127 lines
8.8 KiB
Plaintext
---
|
||
title: "Configure SAML with Okta"
|
||
---
|
||
import Inc0_sso_saml_before_you_begin from './sso-saml-before-you-begin.mdx';
|
||
import Inc1_sso_saml_ldapsync from './sso-saml-ldapsync.mdx';
|
||
import Inc2_sso_saml_faq from './sso-saml-faq.mdx';
|
||
|
||
<PlanAvailability slug="all-commercial" />
|
||
|
||
The following process provides steps to configure SAML 2.0 with Okta for Mattermost.
|
||
|
||
See the [supported SAML encryption methods](/administration-guide/configure/authentication-configuration-settings#supported-saml-encryption-methods) in the authentication configuration settings documentation.
|
||
|
||
<Inc0_sso_saml_before_you_begin />
|
||
|
||
## Set Up a connection app for Mattermost Single Sign-On
|
||
|
||
1. Log in to Okta as an administrator.
|
||
|
||
2. Switch to the **Classic UI**, using the drop-down in the upper left.
|
||
|
||
3. Go to **Admin Dashboard \> Applications \> Add Application**.
|
||
|
||
4. Select **Create New App**, then choose **SAML 2.0** as the Sign on method.
|
||
|
||
> 
|
||
|
||
5. Enter **General Settings** for the application, including **App name** and **App logo** (optional). It's recommended to display the application icon to users, including in the Okta Mobile app. If you’d like to use a Mattermost logo for the application, you can download one [from our page](https://handbook.mattermost.com/operations/operations/publishing/publishing-guidelines/brand-and-visual-design-guidelines).
|
||
|
||
> 
|
||
|
||
6. Enter **SAML Settings**, including:
|
||
|
||
> - **Single sign on URL:** `https://<your-mattermost-url>/login/sso/saml` where `https://<your-mattermost-url>` should typically match the [Mattermost Site URL](/administration-guide/configure/environment-configuration-settings#site-url).
|
||
>
|
||
> - **Audience URI:** For instance, `mattermost`
|
||
>
|
||
> - **Name ID format:** `unspecified`
|
||
>
|
||
> - **Application username:** `Email`
|
||
>
|
||
> > 
|
||
|
||
7. To set up encryption for your SAML connection, select **Show Advanced Settings**.
|
||
|
||

|
||
|
||
8. Set **Assertion Encryption** as **Encrypted**, then upload the Service Provider Public Certificate you generated earlier to the **Encryption Certificate** field.
|
||
|
||
> 
|
||
|
||
9. Enter attribute statements used to map attributes between Okta and Mattermost. For more information on which attributes are configurable, see our [documentation on SAML configuration settings](/administration-guide/configure/authentication-configuration-settings#saml-20). Email and username attributes are required. For SAML with Okta, an [ID attribute](/administration-guide/configure/authentication-configuration-settings#id-attribute) is also required, and that ID must be mapped to `user.id`.
|
||
|
||
> 
|
||
|
||
10. Select **Next**. Then, set Okta support parameters for the application. Recommended settings:
|
||
|
||
> - **I’m an Okta customer adding an internal app**
|
||
>
|
||
> - **This is an internal app that we have created**
|
||
>
|
||
> > 
|
||
|
||
11. Select **Finish**.
|
||
|
||
12. In the Mattermost System Console, go to **Authentication \> SAML 2.0**, then set **Override SAML bind data with AD/LDAP information** to **false** if currently set to **true**. You can re-enable [this configuration setting](/administration-guide/configure/authentication-configuration-settings#override-saml-bind-data-with-adldap-information) later when once setup is complete.
|
||
|
||
13. On the next screen, select the **Sign On** tab, then select **View Setup Instructions**.
|
||
|
||
14. Select the **Identity Provider metadata** link, then copy the link from the browser URL field. This will be used during the SAML configuration steps in the next section.
|
||
|
||

|
||
|
||
15. Take note of **Identity Provider Single Sign-On URL** (also known as **SAML SSO URL**), and the Identity Provider Issuer, as both may be needed to configure SAML for Mattermost.
|
||
|
||
16. Download the X.509 Certificate file and save it. You may need to upload it to Mattermost in a later step.
|
||
|
||

|
||
|
||
## Configure SAML Sign-On for Mattermost
|
||
|
||
Start the Mattermost server and log in to Mattermost as a system admin. Go to **System Console \> Authentication \> SAML 2.0**, then paste the copied Identity Provider Metadata URL in the **Identity Provider Metadata URL** field and select **Get SAML Metadata from IdP**.
|
||
|
||
This populates the **SAML SSO URL** and the **Identity Provider Issuer URL** fields automatically. The Identity Provider Public Certificate is also downloaded from the server and set locally.
|
||
|
||
Alternatively you can enter the following fields manually:
|
||
- **SAML SSO URL:** `Identity Provider Single Sign-On URL` from Okta, specified earlier.
|
||
|
||
- **Identity Provider Issuer URL:** `Identity Provider Issuer` from Okta, specified earlier.
|
||
|
||
- **Identity Provider Public Certificate:** X.509 Public Certificate file you downloaded from Okta earlier.
|
||
|
||
> 
|
||
|
||
2. Configure Mattermost to verify the signature. The **Service Provider Login URL** is the `Single sign on URL` you specified in Okta earlier.
|
||
|
||
> 
|
||
|
||
3. Enable encryption based on the parameters provided earlier.
|
||
|
||
> 
|
||
|
||
4. Configure Mattermost to sign SAML requests using the Service Provider Private Key.
|
||
|
||
5. Set attributes for the SAML Assertions used to update user information in Mattermost.
|
||
- Attributes for Email, Username, and Id are required and should match the values you entered in Okta earlier.
|
||
|
||

|
||
|
||
6. (Optional) Customize the login button text.
|
||
|
||
> 
|
||
|
||
7. Select **Save**.
|
||
|
||
8. (Optional) If you configured `First Name` Attribute and `Last Name` Attribute, go to **System Console \> Site Configuration \> Users and Teams**, then set **Teammate Name Display** to **Show first and last name**. This is recommended for a better user experience.
|
||
|
||
Once complete, and to confirm SAML SSO is successfully enabled, switch your system admin account from email to SAML-based authentication from your profile picture via **Profile \> Security \> Sign-in Method \> Switch to SAML SSO**, then log in with your SAML credentials to complete the switch.
|
||
|
||
We also recommend that you post an announcement for your users to explain how the migration will work.
|
||
|
||
You may also configure SAML for Okta by editing the `config.json` file to enable SAML based on [SAML configuration settings](/administration-guide/configure/authentication-configuration-settings#saml-20). You must restart the Mattermost server for the changes to take effect.
|
||
|
||
<Inc1_sso_saml_ldapsync />
|
||
|
||
<Inc2_sso_saml_faq />
|