mirror of
https://git.anonymousland.org/anonymousland/synapse.git
synced 2025-05-06 18:44:57 -04:00
Add support for registering with a threepid to the HS (get credentials from the client and check them against an ID server).
This commit is contained in:
parent
ddc16d8642
commit
d6ecbbdf0a
3 changed files with 100 additions and 9 deletions
|
@ -47,10 +47,15 @@ class RegisterRestServlet(RestServlet):
|
|||
except KeyError:
|
||||
pass # user_id is optional
|
||||
|
||||
threepidCreds = None
|
||||
if 'threepidCreds' in register_json:
|
||||
threepidCreds = register_json['threepidCreds']
|
||||
|
||||
handler = self.handlers.registration_handler
|
||||
(user_id, token) = yield handler.register(
|
||||
localpart=desired_user_id,
|
||||
password=password)
|
||||
password=password,
|
||||
threepidCreds=threepidCreds)
|
||||
|
||||
result = {
|
||||
"user_id": user_id,
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue