mirror of
https://git.anonymousland.org/anonymousland/synapse.git
synced 2025-08-01 05:06:02 -04:00
Support 3PID login in password providers (#4931)
Adds a new method, check_3pid_auth, which gives password providers the chance to allow authentication with third-party identifiers such as email or msisdn.
This commit is contained in:
parent
903f04c21f
commit
bbd244c7b2
8 changed files with 137 additions and 26 deletions
|
@ -147,8 +147,14 @@ class BaseProfileHandler(BaseHandler):
|
|||
|
||||
@defer.inlineCallbacks
|
||||
def set_displayname(self, target_user, requester, new_displayname, by_admin=False):
|
||||
"""target_user is the user whose displayname is to be changed;
|
||||
auth_user is the user attempting to make this change."""
|
||||
"""Set the displayname of a user
|
||||
|
||||
Args:
|
||||
target_user (UserID): the user whose displayname is to be changed.
|
||||
requester (Requester): The user attempting to make this change.
|
||||
new_displayname (str): The displayname to give this user.
|
||||
by_admin (bool): Whether this change was made by an administrator.
|
||||
"""
|
||||
if not self.hs.is_mine(target_user):
|
||||
raise SynapseError(400, "User is not hosted on this Home Server")
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue