mirror of
https://github.com/matrix-org/matrix-spec
synced 2026-03-26 13:04:10 +01:00
Add some "[Changed in this version]" for individual auth rules
For rooms v7 and v8, we can decorate individual auth rules to show what has changed.
This commit is contained in:
parent
c50b3e808a
commit
740770a308
|
|
@ -51,7 +51,8 @@ The rules are as follows:
|
||||||
4. If type is `m.room.member`:
|
4. If type is `m.room.member`:
|
||||||
1. If there is no `state_key` property, or no `membership` property in
|
1. If there is no `state_key` property, or no `membership` property in
|
||||||
`content`, reject.
|
`content`, reject.
|
||||||
2. If `content` has a `join_authorised_via_users_server` property:
|
2. {{< added-in this=true >}}
|
||||||
|
If `content` has a `join_authorised_via_users_server` property:
|
||||||
1. If the event is not validly signed by the homeserver of the user ID denoted
|
1. If the event is not validly signed by the homeserver of the user ID denoted
|
||||||
by the key, reject.
|
by the key, reject.
|
||||||
3. If `membership` is `join`:
|
3. If `membership` is `join`:
|
||||||
|
|
@ -61,7 +62,8 @@ The rules are as follows:
|
||||||
3. If the `sender` is banned, reject.
|
3. If the `sender` is banned, reject.
|
||||||
4. If the `join_rule` is `invite` or `knock` then allow if
|
4. If the `join_rule` is `invite` or `knock` then allow if
|
||||||
membership state is `invite` or `join`.
|
membership state is `invite` or `join`.
|
||||||
5. If the `join_rule` is `restricted`:
|
5. {{< added-in this=true >}}
|
||||||
|
If the `join_rule` is `restricted`:
|
||||||
1. If membership state is `join` or `invite`, allow.
|
1. If membership state is `join` or `invite`, allow.
|
||||||
2. If the `join_authorised_via_users_server` key in `content`
|
2. If the `join_authorised_via_users_server` key in `content`
|
||||||
is not a user with sufficient permission to invite other
|
is not a user with sufficient permission to invite other
|
||||||
|
|
|
||||||
|
|
@ -83,7 +83,8 @@ The rules are as follows:
|
||||||
`state_key` is the creator, allow.
|
`state_key` is the creator, allow.
|
||||||
2. If the `sender` does not match `state_key`, reject.
|
2. If the `sender` does not match `state_key`, reject.
|
||||||
3. If the `sender` is banned, reject.
|
3. If the `sender` is banned, reject.
|
||||||
4. If the `join_rule` is `invite` or `knock` then allow if
|
4. {{< changed-in this=true >}}
|
||||||
|
If the `join_rule` is `invite` or `knock` then allow if
|
||||||
membership state is `invite` or `join`.
|
membership state is `invite` or `join`.
|
||||||
5. If the `join_rule` is `public`, allow.
|
5. If the `join_rule` is `public`, allow.
|
||||||
6. Otherwise, reject.
|
6. Otherwise, reject.
|
||||||
|
|
@ -114,7 +115,8 @@ The rules are as follows:
|
||||||
the *invite level*, allow.
|
the *invite level*, allow.
|
||||||
5. Otherwise, reject.
|
5. Otherwise, reject.
|
||||||
4. If `membership` is `leave`:
|
4. If `membership` is `leave`:
|
||||||
1. If the `sender` matches `state_key`, allow if and only if
|
1. {{< changed-in this=true >}}
|
||||||
|
If the `sender` matches `state_key`, allow if and only if
|
||||||
that user's current membership state is `invite`, `join`,
|
that user's current membership state is `invite`, `join`,
|
||||||
or `knock`.
|
or `knock`.
|
||||||
2. If the `sender`'s current membership state is not `join`,
|
2. If the `sender`'s current membership state is not `join`,
|
||||||
|
|
@ -133,7 +135,8 @@ The rules are as follows:
|
||||||
the *ban level*, and the *target user*'s power level is less
|
the *ban level*, and the *target user*'s power level is less
|
||||||
than the `sender`'s power level, allow.
|
than the `sender`'s power level, allow.
|
||||||
3. Otherwise, reject.
|
3. Otherwise, reject.
|
||||||
6. If `membership` is `knock`:
|
6. {{< added-in this=true >}}
|
||||||
|
If `membership` is `knock`:
|
||||||
1. If the `join_rule` is anything other than `knock`, reject.
|
1. If the `join_rule` is anything other than `knock`, reject.
|
||||||
2. If `sender` does not match `state_key`, reject.
|
2. If `sender` does not match `state_key`, reject.
|
||||||
3. If the `sender`'s current membership is not `ban` or `join`, allow.
|
3. If the `sender`'s current membership is not `ban` or `join`, allow.
|
||||||
|
|
|
||||||
|
|
@ -21,5 +21,6 @@
|
||||||
{{ $content := $page.Content }}
|
{{ $content := $page.Content }}
|
||||||
{{ if not $withVersioning }}
|
{{ if not $withVersioning }}
|
||||||
{{ $content = (replace $content "[New in this version]" "") }}
|
{{ $content = (replace $content "[New in this version]" "") }}
|
||||||
|
{{ $content = (replace $content "[Changed in this version]" "") }}
|
||||||
{{ end }}
|
{{ end }}
|
||||||
{{ $content | safeHTML }}
|
{{ $content | safeHTML }}
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue