# Discourse as an SAML, OAUTH IDP?

**URL:** https://meta.discourse.org/t/discourse-as-an-saml-oauth-idp/29898
**Category:** SSO
**Tags:** discourseconnect
**Created:** [11 juni 2015 om 18:05 UTC](https://meta.discourse.org/t/discourse-as-an-saml-oauth-idp/29898 "2015-06-11T18:05:04Z")
**Posts on this page:** 5
**Page:** 1

<div class="post-metadata">

### Author: ![Breaker](https://avatars.discourse-cdn.com/v4/letter/b/9fc348/32.png) [@Breaker](https://meta.discourse.org/u/Breaker)
#### Post date: [11 juni 2015 om 18:05 UTC](https://meta.discourse.org/t/discourse-as-an-saml-oauth-idp/29898/1 "2015-06-11T18:05:04Z")

</div>

I was wondering if anyone knows of a way to have discourse act as an IDP (identity Provider) using SAML or OAUTH2.

im thinking about setting up a network of sites and would like for the forums to be the central spot for logging in.

I did notice on the boards here that CAS is enabled by default. That might work however if I read correctly it is limited to same domain emails? is this correct?

---

<div class="post-metadata">

### Author: ![sam](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/sam/32/102149_2.png) [@sam](https://meta.discourse.org/u/sam)
#### Post date: [7 november 2016 om 00:17 UTC](https://meta.discourse.org/t/discourse-as-an-saml-oauth-idp/29898/3 "2016-11-07T00:17:49Z")

</div>

See:

> [@Use Discourse as an identity provider (SSO, DiscourseConnect)](https://meta.discourse.org/t/using-discourse-as-a-sso-provider/32974):
>
> So you want to use Discourse as an identity provider for your own web app? Great! Let’s get started. Enable [DiscourseConnect](https://meta.discourse.org/t/13045?silent=true) provider setting Under Discourse admin site settings (/admin/site\_settings) enable setting enable discourse connect provider and add a secret string to discourse connect provider secrets (used to hash SSO payloads). Implement [DiscourseConnect](https://meta.discourse.org/t/13045?silent=true) in your web app: Generate a random [nonce](https://en.wikipedia.org/wiki/Cryptographic_nonce). Let’s call this value NONCE. Save it temporarily so that you can verify it with the …

That is built in, OAUTH2 provider etc would require a custom built plugin, no such plugin exists.

---

<div class="post-metadata">

### Author: ![system](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/system/32/443519_2.png) [@system](https://meta.discourse.org/u/system)
#### Post date: [25 maart 2019 om 12:27 UTC](https://meta.discourse.org/t/discourse-as-an-saml-oauth-idp/29898/4 "2019-03-25T12:27:15Z")

</div>



---

<div class="post-metadata">

### Author: ![system](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/system/32/443519_2.png) [@system](https://meta.discourse.org/u/system)
#### Post date: [21 mei 2022 om 06:55 UTC](https://meta.discourse.org/t/discourse-as-an-saml-oauth-idp/29898/5 "2022-05-21T06:55:15Z")

</div>



---

<div class="post-metadata">

### Author: ![itsbhanusharma](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/itsbhanusharma/32/180717_2.png) [@itsbhanusharma](https://meta.discourse.org/u/itsbhanusharma)
#### Post date: [21 mei 2022 om 07:52 UTC](https://meta.discourse.org/t/discourse-as-an-saml-oauth-idp/29898/6 "2022-05-21T07:52:40Z")

</div>


