| 1 |
Synapse Matrix home server |
| 2 |
========================== |
| 3 |
|
| 4 |
|image0| |
| 5 |
|
| 6 |
Presentation |
| 7 |
------------ |
| 8 |
|
| 9 |
Synapse is the reference implementation of a Matrix home server, written in Python. |
| 10 |
|
| 11 |
Configuring Synapse |
| 12 |
------------------- |
| 13 |
|
| 14 |
See `The official Synapse documentation <https://matrix-org.github.io/synapse/latest/openid.html>`__ for details |
| 15 |
|
| 16 |
|
| 17 |
.. code:: yaml |
| 18 |
|
| 19 |
oidc_providers: |
| 20 |
- idp_id: lemonldap |
| 21 |
idp_name: lemonldap |
| 22 |
discover: true |
| 23 |
issuer: "https://auth.example.com/" # TO BE FILLED: replace with your domain |
| 24 |
client_id: "your client id" # TO BE FILLED |
| 25 |
client_secret: "your client secret" # TO BE FILLED |
| 26 |
scopes: |
| 27 |
- "openid" |
| 28 |
- "profile" |
| 29 |
- "email" |
| 30 |
user_profile_method: "userinfo_endpoint" # Required if you see "localpart" error in Matrix logs |
| 31 |
user_mapping_provider: |
| 32 |
config: |
| 33 |
localpart_template: "{{ user.preferred_username }}" |
| 34 |
# TO BE FILLED: If your users have names in LemonLDAP::NG and you want those in Synapse, this should be replaced with user.name|capitalize or any valid filter. |
| 35 |
display_name_template: "{{ user.preferred_username|capitalize }}" |
| 36 |
|
| 37 |
|
| 38 |
Configuring LemonLDAP |
| 39 |
~~~~~~~~~~~~~~~~~~~~~ |
| 40 |
|
| 41 |
Add a :doc:`new OpenID Connect relying party<..//idpopenidconnect>` |
| 42 |
with the following parameters: |
| 43 |
|
| 44 |
* **Options/Basic** |
| 45 |
* **Client ID**: same as ``client_id`` configuration in Synapse |
| 46 |
* **Client Secret**: same as ``client_secret`` configuration in Synapse |
| 47 |
* **Allowed redirection addresses**: ``[synapse public baseurl]/_synapse/client/oidc/callback`` |
| 48 |
* **Options/Security** |
| 49 |
* **ID Token signature algorithm**:: ``RS256`` |
| 50 |
* **Options/Logout** |
| 51 |
* **Type**: 'Back Channel' |
| 52 |
* **URL**: ``[synapse public baseurl]/_synapse/client/oidc/backchannel_logout`` |
| 53 |
* **Session Supported**: ``On`` |
| 54 |
* **Exported Attributes** |
| 55 |
* ``preferred_username``: ``uid`` |
| 56 |
|
| 57 |
(adjust if you don't store your username attribute in the ``uid`` session variable |
| 58 |
|
| 59 |
.. |image0| image:: /applications/matrix_logo.png |
| 60 |
:class: align-center |
| 61 |
|