summary refs log tree commit diff
path: root/synapse/event_auth.py
diff options
context:
space:
mode:
authorPatrick Cloke <clokep@users.noreply.github.com>2020-03-09 08:58:25 -0400
committerGitHub <noreply@github.com>2020-03-09 08:58:25 -0400
commit06eb5cae08272c401a586991fc81f788825f910b (patch)
treebabdb2ec370f203ad74119351c99d0e1a8ea843f /synapse/event_auth.py
parentUpdate routing of fallback auth in the worker docs. (#7048) (diff)
downloadsynapse-06eb5cae08272c401a586991fc81f788825f910b.tar.xz
Remove special auth and redaction rules for aliases events in experimental room ver. (#7037)
Diffstat (limited to 'synapse/event_auth.py')
-rw-r--r--synapse/event_auth.py8
1 files changed, 3 insertions, 5 deletions
diff --git a/synapse/event_auth.py b/synapse/event_auth.py
index 472f165044..46beb5334f 100644
--- a/synapse/event_auth.py
+++ b/synapse/event_auth.py
@@ -137,7 +137,7 @@ def check(
             raise AuthError(403, "This room has been marked as unfederatable.")
 
     # 4. If type is m.room.aliases
-    if event.type == EventTypes.Aliases:
+    if event.type == EventTypes.Aliases and room_version_obj.special_case_aliases_auth:
         # 4a. If event has no state_key, reject
         if not event.is_state():
             raise AuthError(403, "Alias event must be a state event")
@@ -152,10 +152,8 @@ def check(
             )
 
         # 4c. Otherwise, allow.
-        # This is removed by https://github.com/matrix-org/matrix-doc/pull/2260
-        if room_version_obj.special_case_aliases_auth:
-            logger.debug("Allowing! %s", event)
-            return
+        logger.debug("Allowing! %s", event)
+        return
 
     if logger.isEnabledFor(logging.DEBUG):
         logger.debug("Auth events: %s", [a.event_id for a in auth_events.values()])