From 6abe71386b946a09a88b615ab8f2fe0480e9c039 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=C5=A0imon=20Brandner?= Date: Sun, 17 Jul 2022 20:48:14 +0200 Subject: [PATCH] MSC3786: Add a default push rule to ignore `m.room.server_acl` events (#3786) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * Add a default push rule to ignore `m.room.server_acl` events Signed-off-by: Šimon Brandner * Update MSC number Signed-off-by: Šimon Brandner * Add prefix `.` Signed-off-by: Šimon Brandner * Link to spec Co-authored-by: Richard van der Hoff <1389908+richvdh@users.noreply.github.com> * Be more explicit about why the rule is needed Signed-off-by: Šimon Brandner * Clarify push rule ordering Signed-off-by: Šimon Brandner * Don't rely on unmerged MSCs for ordering Signed-off-by: Šimon Brandner * Be even more explicit about why we need this Signed-off-by: Šimon Brandner * Improve wording Co-authored-by: Richard van der Hoff <1389908+richvdh@users.noreply.github.com> * Improve wording Co-authored-by: Richard van der Hoff <1389908+richvdh@users.noreply.github.com> * Improve wording Co-authored-by: Richard van der Hoff <1389908+richvdh@users.noreply.github.com> * Add missing period Co-authored-by: Richard van der Hoff <1389908+richvdh@users.noreply.github.com> * Add spec link Co-authored-by: Richard van der Hoff <1389908+richvdh@users.noreply.github.com> * Remove `when merged` Co-authored-by: Richard van der Hoff <1389908+richvdh@users.noreply.github.com> * Remove `dont_notify` Co-authored-by: Richard van der Hoff <1389908+richvdh@users.noreply.github.com> * Check `state_key` Signed-off-by: Šimon Brandner Co-authored-by: Richard van der Hoff <1389908+richvdh@users.noreply.github.com> --- proposals/3786-acl-notifs.md | 50 ++++++++++++++++++++++++++++++++++++ 1 file changed, 50 insertions(+) create mode 100644 proposals/3786-acl-notifs.md diff --git a/proposals/3786-acl-notifs.md b/proposals/3786-acl-notifs.md new file mode 100644 index 00000000..ee743425 --- /dev/null +++ b/proposals/3786-acl-notifs.md @@ -0,0 +1,50 @@ +# MSC3786: Add a default push rule to ignore `m.room.server_acl` events + +`m.room.server_acl` events allow for expressing which servers can participate in +a room. Room server ACLs aren't something the user should have to worry about, +so these events should not trigger notifications; however right now they *do* +trigger notifications, if the user has the room rule set to `notify` (`All +messages` in Element). + +Additionally, these events are often sent quite frequently during spam attacks, +which causes the users to be overwhelmed by +notifications. (See .) + +Due to these problems, this MSC proposes a new push rule to ignore these events. +The new push rule is analogous to `.m.rule.member_event` (see ), or `.m.rule.reaction` +(from [MSC2153](https://github.com/matrix-org/matrix-spec-proposals/pull/2153) +or [MSC2677](https://github.com/matrix-org/matrix-spec-proposals/pull/2677)). + +## Proposal + +A new [default override +rule](https://spec.matrix.org/v1.2/client-server-api/#default-override-rules) is +to be added that ignores `m.room.server_acl` events: + +```json +{ + "rule_id": ".m.rule.room.server_acl", + "default": true, + "enabled": true, + "conditions": [ + { + "kind": "event_match", + "key": "type", + "pattern": "m.room.server_acl" + }, + { + "kind": "event_match", + "key": "state_key", + "pattern": "" + } + ], + "actions": [] +} +``` + +This new push rule is inserted immediately after `.m.rule.tombstone`. + +## Unstable prefix + +During development, `.org.matrix.msc3786.rule.room.server_acl` is to be used +instead of `.m.rule.room.server_acl`.