11# Mass redactions
22Matrix, like any platform with public chat rooms, has spammers. Currently,
33redacting spam essentially requires spamming redaction events in a 1:1 ratio,
4- which is not optimal<sup >[ 1] </sup >. Most clients do not even have any mass
5- redaction tools, likely in part due to the lack of a mass redaction API. A mass
6- redaction API on the other hand has not been implemented as it would require
7- sending lots of events at once. However, this problem could be solved by
8- allowing a single redaction event to redact many events instead of sending many
9- redaction events.
4+ which is not optimal<sup >[ 1] ( images/2244-redaction-spam.png ) </sup >. Most
5+ clients do not even have any mass redaction tools, likely in part due to the
6+ lack of a mass redaction API. A mass redaction API on the other hand has not
7+ been implemented as it would require sending lots of events at once. However,
8+ this problem could be solved by allowing a single redaction event to redact
9+ many events instead of sending many redaction events.
1010
1111## Proposal
12- This proposal builds upon [ MSC2174] and suggests making the ` redacts ` field
13- in the content of ` m.room.redaction ` events an array of event ID strings
14- instead of a single event ID string.
12+ This proposal builds upon [ MSC2174] ( https://github.com/matrix-org/matrix-doc/pull/2174 )
13+ and suggests making the ` redacts ` field in the content of ` m.room.redaction `
14+ events an array of event ID strings instead of a single event ID string.
1515
1616It would be easiest to do this before MSC2174 is written into the spec, as then
1717only one migration would be needed: from an event-level redacts string to a
@@ -36,17 +36,17 @@ rejected: soft failing until all targets are found or handling each target
3636separately.
3737
3838#### Soft fail
39- [ Soft fail] the event until all targets are found, then accept only if the
40- sender has the privileges to redact every listed event. This is how redactions
41- currently work.
39+ [ Soft fail] ( https://matrix.org/docs/spec/server_server/r0.1.3#soft-failure ) the
40+ event until all targets are found, then accept only if the sender has the
41+ privileges to redact every listed event. This is how redactions currently work.
4242
4343This has the downside of requiring servers to fetch all the target events (and
4444possibly forward them to clients) before being able to process and forward the
4545redaction event.
4646
4747#### Handle each target separately
4848The target events of an ` m.room.redaction ` shall no longer be considered when
49- authorizing of an ` m.room.redaction ` event. Any other existing rules remain
49+ authorizing an ` m.room.redaction ` event. Any other existing rules remain
5050unchanged.
5151
5252When a server accepts an ` m.room.redaction ` using the modified auth rules, it
@@ -76,8 +76,3 @@ to this is omitting the list of redacted event IDs from the data in the
7676` redacted_because ` field.
7777
7878## Security considerations
79-
80-
81- [ 1 ] : https://img.mau.lu/hEqqt.png
82- [ MSC2174 ] : https://github.com/matrix-org/matrix-doc/pull/2174
83- [ Soft fail ] : https://matrix.org/docs/spec/server_server/r0.1.3#soft-failure
0 commit comments