Skip to content
This repository has been archived by the owner on Apr 26, 2024. It is now read-only.

Drop triple s from enable_registration_token_3pid_bypass #12639

Merged
merged 2 commits into from
May 5, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions changelog.d/12639.bugfix
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
Add new `enable_registration_token_3pid_bypass` configuration option to allow registrations via token as an alternative to verifying a 3pid.
4 changes: 2 additions & 2 deletions synapse/config/registration.py
Original file line number Diff line number Diff line change
Expand Up @@ -43,8 +43,8 @@ def read_config(self, config: JsonDict, **kwargs: Any) -> None:
self.registration_requires_token = config.get(
"registration_requires_token", False
)
self.enable_registration_token_3pid_bypasss = config.get(
"enable_registration_token_3pid_bypasss", False
self.enable_registration_token_3pid_bypass = config.get(
"enable_registration_token_3pid_bypass", False
)
self.registration_shared_secret = config.get("registration_shared_secret")

Expand Down
2 changes: 1 addition & 1 deletion synapse/handlers/ui_auth/checkers.py
Original file line number Diff line number Diff line change
Expand Up @@ -258,7 +258,7 @@ def __init__(self, hs: "HomeServer"):
self.hs = hs
self._enabled = bool(
hs.config.registration.registration_requires_token
) or bool(hs.config.registration.enable_registration_token_3pid_bypasss)
) or bool(hs.config.registration.enable_registration_token_3pid_bypass)
self.store = hs.get_datastores().main

def is_enabled(self) -> bool:
Expand Down
2 changes: 1 addition & 1 deletion synapse/rest/client/register.py
Original file line number Diff line number Diff line change
Expand Up @@ -930,7 +930,7 @@ def _calculate_registration_flows(
flows.append([LoginType.MSISDN, LoginType.EMAIL_IDENTITY])

# Add a flow that doesn't require any 3pids, if the config requests it.
if config.registration.enable_registration_token_3pid_bypasss:
if config.registration.enable_registration_token_3pid_bypass:
flows.append([LoginType.REGISTRATION_TOKEN])

# Prepend m.login.terms to all flows if we're requiring consent
Expand Down