Merge pull request #1584 from turt2live/travis/general/state-key-restriction
Update schemas and auth rules to cover the @ state key restriction
This commit is contained in:
commit
e401b7255c
2 changed files with 9 additions and 2 deletions
|
@ -11,7 +11,11 @@ properties:
|
||||||
state_key:
|
state_key:
|
||||||
description: A unique key which defines the overwriting semantics for this piece
|
description: A unique key which defines the overwriting semantics for this piece
|
||||||
of room state. This value is often a zero-length string. The presence of this
|
of room state. This value is often a zero-length string. The presence of this
|
||||||
key makes this event a State Event. The key MUST NOT start with '_'.
|
key makes this event a State Event.
|
||||||
|
|
||||||
|
State keys starting with an ``@`` are reserved for referencing user IDs, such
|
||||||
|
as room members. With the exception of a few events, state events set with a
|
||||||
|
given user's ID as the state key MUST only be set by that user.
|
||||||
type: string
|
type: string
|
||||||
required:
|
required:
|
||||||
- state_key
|
- state_key
|
||||||
|
|
|
@ -105,7 +105,10 @@ properties:
|
||||||
title: EventContent
|
title: EventContent
|
||||||
type: object
|
type: object
|
||||||
state_key:
|
state_key:
|
||||||
description: The ``user_id`` this membership event relates to.
|
description: |-
|
||||||
|
The ``user_id`` this membership event relates to. In all cases except for when ``membership`` is
|
||||||
|
``join``, the user ID sending the event does not need to match the user ID in the ``state_key``,
|
||||||
|
unlike other events. Regular authorisation rules still apply.
|
||||||
type: string
|
type: string
|
||||||
type:
|
type:
|
||||||
enum:
|
enum:
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue