Check domain of events properly
Federated servers still need to delegate authority to owning servers
This commit is contained in:
parent
4d1ea40008
commit
b854a375b0
|
@ -561,7 +561,9 @@ class Auth(object):
|
||||||
if user_level > redact_level:
|
if user_level > redact_level:
|
||||||
return False
|
return False
|
||||||
|
|
||||||
if EventID.from_string(event.redacts).domain == self.hs.get_config().server_name:
|
redacter_domain = EventID.from_string(event.event_id).domain
|
||||||
|
redactee_domain = EventID.from_string(event.redacts).domain
|
||||||
|
if redacter_domain == redactee_domain:
|
||||||
return True
|
return True
|
||||||
|
|
||||||
raise AuthError(
|
raise AuthError(
|
||||||
|
|
Loading…
Reference in New Issue