Skip to content

Commit

Permalink
Replace misuses of 'plaintext' with 'cleartext' and clarify spoiler d…
Browse files Browse the repository at this point in the history
  • Loading branch information
anoadragon453 authored and clokep committed May 3, 2023
1 parent b15e80b commit e7a86bb
Show file tree
Hide file tree
Showing 4 changed files with 10 additions and 9 deletions.
1 change: 1 addition & 0 deletions changelogs/client_server/newsfragments/1306.clarification
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
Various clarifications throughout the specification.
6 changes: 3 additions & 3 deletions content/client-server-api/_index.md
Original file line number Diff line number Diff line change
Expand Up @@ -1945,14 +1945,14 @@ parent event, for example.
{{% /boxes/note %}}

To allow the server to aggregate and find child events for a parent, the `m.relates_to`
key of an event MUST be included in the plaintext copy of the event. It cannot be
key of an event MUST be included in the cleartext portion of the event. It cannot be
exclusively recorded in the encrypted payload as the server cannot decrypt the event
for processing.

{{% boxes/warning %}}
If an encrypted event contains an `m.relates_to` in its payload, it should be
ignored and instead favour the plaintext `m.relates_to` copy (including when there
is no plaintext copy). This is to ensure the client's behaviour matches the server's
ignored and instead favour the cleartext `m.relates_to` copy (including when there
is no cleartext copy). This is to ensure the client's behaviour matches the server's
capability to handle relationships.
{{% /boxes/warning %}}

Expand Down
10 changes: 5 additions & 5 deletions content/client-server-api/modules/instant_messaging.md
Original file line number Diff line number Diff line change
Expand Up @@ -327,11 +327,11 @@ If a reason were to be supplied, it would look like:
}
```

When sending a spoiler, clients SHOULD provide the plain text fallback in the `body`
as shown above (including the reason). The fallback SHOULD omit the spoiler text verbatim
since `body` might show up in text-only clients or in notifications. To prevent spoilers
showing up in such situations, clients are strongly encouraged to first upload the plaintext
to the media repository then reference the MXC URI in a markdown-style link, as shown above.
When sending a spoiler, clients SHOULD provide the fallback in the `body` as shown above
(including the reason). The fallback SHOULD NOT include the text containing spoilers since
`body` might show up in text-only clients or in notifications. To prevent spoilers showing up in
such situations, clients are strongly encouraged to first upload the text containing spoilers
to the media repository, then reference the MXC URI in a markdown-style link, as shown above.

Clients SHOULD render spoilers differently with some sort of disclosure. For example, the
client could blur the actual text and ask the user to click on it for it to be revealed.
Expand Down
2 changes: 1 addition & 1 deletion content/identity-service-api.md
Original file line number Diff line number Diff line change
Expand Up @@ -280,7 +280,7 @@ request.

#### `none`

This algorithm performs plaintext lookups on the identity server.
This algorithm performs cleartext lookups on the identity server.
Typically this algorithm should not be used due to the security concerns
of unhashed identifiers, however some scenarios (such as LDAP-backed
identity servers) prevent the use of hashed identifiers. Identity
Expand Down

0 comments on commit e7a86bb

Please sign in to comment.