diff options
author | Warren Bailey <warren@warrenbailey.net> | 2023-03-30 12:09:41 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-03-30 11:09:41 +0000 |
commit | a3bad89d57645b2ea304d2900adab71a786b0172 (patch) | |
tree | d988ad103d961b69548567e9cb7ccf301205bbc7 /synapse/config/oidc.py | |
parent | Add some clarification to the doc/comments regarding TCP replication (#15354) (diff) | |
download | synapse-a3bad89d57645b2ea304d2900adab71a786b0172.tar.xz |
Add the ability to enable/disable registrations when in the OIDC flow (#14978)
Signed-off-by: Warren Bailey <warren@warrenbailey.net>
Diffstat (limited to 'synapse/config/oidc.py')
-rw-r--r-- | synapse/config/oidc.py | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/synapse/config/oidc.py b/synapse/config/oidc.py index df8c422043..77c1d1dc8e 100644 --- a/synapse/config/oidc.py +++ b/synapse/config/oidc.py @@ -136,6 +136,7 @@ OIDC_PROVIDER_CONFIG_SCHEMA = { "type": "array", "items": SsoAttributeRequirement.JSON_SCHEMA, }, + "enable_registration": {"type": "boolean"}, }, } @@ -306,6 +307,7 @@ def _parse_oidc_config_dict( user_mapping_provider_class=user_mapping_provider_class, user_mapping_provider_config=user_mapping_provider_config, attribute_requirements=attribute_requirements, + enable_registration=oidc_config.get("enable_registration", True), ) @@ -405,3 +407,6 @@ class OidcProviderConfig: # required attributes to require in userinfo to allow login/registration attribute_requirements: List[SsoAttributeRequirement] + + # Whether automatic registrations are enabled in the ODIC flow. Defaults to True + enable_registration: bool |