summary refs log tree commit diff
path: root/synapse/rest/admin
diff options
context:
space:
mode:
authorCallum Brown <callum@calcuode.com>2021-09-23 18:58:12 +0100
committerGitHub <noreply@github.com>2021-09-23 17:58:12 +0000
commit90d9fc750514b1ede327f1dfe6e0a1c09b281d6d (patch)
tree2c25d8a82444c360c872a0a812f28ce85dde2d03 /synapse/rest/admin
parentFactor out `_get_remote_auth_chain_for_event` from `_update_auth_events_and_c... (diff)
downloadsynapse-90d9fc750514b1ede327f1dfe6e0a1c09b281d6d.tar.xz
Allow `.` and `~` chars in registration tokens (#10887)
Per updates to MSC3231 in order to use the same grammar
as other identifiers.
Diffstat (limited to 'synapse/rest/admin')
-rw-r--r--synapse/rest/admin/registration_tokens.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/synapse/rest/admin/registration_tokens.py b/synapse/rest/admin/registration_tokens.py
index 5a1c929d85..aba48f6e7b 100644
--- a/synapse/rest/admin/registration_tokens.py
+++ b/synapse/rest/admin/registration_tokens.py
@@ -113,7 +113,7 @@ class NewRegistrationTokenRestServlet(RestServlet):
         self.store = hs.get_datastore()
         self.clock = hs.get_clock()
         # A string of all the characters allowed to be in a registration_token
-        self.allowed_chars = string.ascii_letters + string.digits + "-_"
+        self.allowed_chars = string.ascii_letters + string.digits + "._~-"
         self.allowed_chars_set = set(self.allowed_chars)
 
     async def on_POST(self, request: SynapseRequest) -> Tuple[int, JsonDict]: