mirror of
https://mau.dev/maunium/synapse.git
synced 2024-11-09 19:44:32 +01:00
Also check the domains for membership state_keys
This commit is contained in:
parent
187320b019
commit
9b05ef6f39
1 changed files with 9 additions and 0 deletions
|
@ -190,6 +190,15 @@ class Auth(object):
|
|||
|
||||
target_user_id = event.state_key
|
||||
|
||||
creating_domain = RoomID.from_string(event.room_id).domain
|
||||
target_domain = UserID.from_string(target_user_id).domain
|
||||
if creating_domain != target_domain:
|
||||
if not self.can_federate(event, auth_events):
|
||||
raise AuthError(
|
||||
403,
|
||||
"This room has been marked as unfederatable."
|
||||
)
|
||||
|
||||
# get info about the caller
|
||||
key = (EventTypes.Member, event.user_id, )
|
||||
caller = auth_events.get(key)
|
||||
|
|
Loading…
Reference in a new issue