mirror of
https://mau.dev/maunium/synapse.git
synced 2024-12-16 00:23:50 +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
|
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
|
# get info about the caller
|
||||||
key = (EventTypes.Member, event.user_id, )
|
key = (EventTypes.Member, event.user_id, )
|
||||||
caller = auth_events.get(key)
|
caller = auth_events.get(key)
|
||||||
|
|
Loading…
Reference in a new issue