summary refs log tree commit diff
path: root/synapse/handlers/federation.py
diff options
context:
space:
mode:
authorErik Johnston <erik@matrix.org>2017-06-19 12:36:28 +0100
committerErik Johnston <erik@matrix.org>2017-06-19 12:37:27 +0100
commitd7fe6b356c5b74ffc5681f85a0d6100f4b4f2295 (patch)
treed5695155a2dc3779be156bef18445a102660c6e3 /synapse/handlers/federation.py
parentadd missing boolean to synapse_port_db (diff)
downloadsynapse-d7fe6b356c5b74ffc5681f85a0d6100f4b4f2295.tar.xz
Add shutdown room API
Diffstat (limited to 'synapse/handlers/federation.py')
-rw-r--r--synapse/handlers/federation.py4
1 files changed, 4 insertions, 0 deletions
diff --git a/synapse/handlers/federation.py b/synapse/handlers/federation.py
index 39d2bee8da..f7ae369a1d 100644
--- a/synapse/handlers/federation.py
+++ b/synapse/handlers/federation.py
@@ -1068,6 +1068,10 @@ class FederationHandler(BaseHandler):
         """
         event = pdu
 
+        is_blocked = yield self.store.is_room_blocked(event.room_id)
+        if is_blocked:
+            raise SynapseError(403, "This room has been blocked on this server")
+
         event.internal_metadata.outlier = True
         event.internal_metadata.invite_from_remote = True