diff options
author | Mark Haines <mjark@negativecurvature.net> | 2016-07-18 15:04:47 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2016-07-18 15:04:47 +0100 |
commit | a292454aa1bc151ef1f5bd1ea67493bde760ddfd (patch) | |
tree | 3bc4b6bda8b91b3c00ec81034477f6f696b34507 | |
parent | Merge pull request #927 from Half-Shot/develop (diff) | |
parent | Fix 500 ISE when sending alias event without a state_key (diff) | |
download | synapse-a292454aa1bc151ef1f5bd1ea67493bde760ddfd.tar.xz |
Merge pull request #925 from matrix-org/markjh/auth_fix
Fix 500 ISE when sending alias event without a state_key
-rw-r--r-- | synapse/api/auth.py | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/synapse/api/auth.py b/synapse/api/auth.py index 3d1ce4e09e..be67ab4f4d 100644 --- a/synapse/api/auth.py +++ b/synapse/api/auth.py @@ -121,6 +121,11 @@ class Auth(object): # FIXME: Temp hack if event.type == EventTypes.Aliases: + if not event.is_state(): + raise AuthError( + 403, + "Alias event must be a state event", + ) if not event.state_key: raise AuthError( 403, |