summary refs log tree commit diff
path: root/synapse/handlers/message.py
diff options
context:
space:
mode:
authorNeil Johnson <neil@matrix.org>2018-08-17 14:04:15 +0100
committerNeil Johnson <neil@matrix.org>2018-08-17 14:04:15 +0100
commitb5f638f1f478d2e7912d7afc454e881f4677d78c (patch)
tree2194c747d8c267e2d1f5c490faf80867dba61fc7 /synapse/handlers/message.py
parentflake8 (diff)
parentMerge pull request #3708 from matrix-org/neilj/resource_Limit_block_event_cre... (diff)
downloadsynapse-b5f638f1f478d2e7912d7afc454e881f4677d78c.tar.xz
Merge branch 'develop' of github.com:matrix-org/synapse into neilj/server_notices_on_blocking
Diffstat (limited to 'synapse/handlers/message.py')
-rw-r--r--synapse/handlers/message.py6
1 files changed, 5 insertions, 1 deletions
diff --git a/synapse/handlers/message.py b/synapse/handlers/message.py
index 893c9bcdc4..4d006df63c 100644
--- a/synapse/handlers/message.py
+++ b/synapse/handlers/message.py
@@ -276,10 +276,14 @@ class EventCreationHandler(object):
                 where *hashes* is a map from algorithm to hash.
 
                 If None, they will be requested from the database.
-
+        Raises:
+            ResourceLimitError if server is blocked to some resource being
+            exceeded
         Returns:
             Tuple of created event (FrozenEvent), Context
         """
+        yield self.auth.check_auth_blocking(requester.user.to_string())
+
         builder = self.event_builder_factory.new(event_dict)
 
         self.validator.validate_new(builder)