Skip to content

Commit

Permalink
fallback keys should have a "fallback: true" property (#1676)
Browse files Browse the repository at this point in the history
* fallback keys should have a "fallback: true" property

* add changelog
  • Loading branch information
uhoreg authored Nov 29, 2023
1 parent 6fe2ff4 commit 62c377e
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 1 deletion.
1 change: 1 addition & 0 deletions changelogs/client_server/newsfragments/1676.clarification
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
Indicate that fallback keys should have a `fallback` property set to `true`.
5 changes: 4 additions & 1 deletion content/client-server-api/modules/end_to_end_encryption.md
Original file line number Diff line number Diff line change
Expand Up @@ -77,6 +77,7 @@ algorithm is represented by an object with the following properties:
|------------|------------|---------------------------------------------------------------------------------------------------------------------------------------------------|
| key | string | **Required.** The unpadded Base64-encoded 32-byte Curve25519 public key. |
| signatures | Signatures | **Required.** Signatures of the key object. The signature is calculated using the process described at [Signing JSON](/appendices/#signing-json). |
| fallback | boolean | Indicates whether this is a [fallback key](#one-time-and-fallback-keys). Defaults to `false`. |

Example:

Expand Down Expand Up @@ -150,7 +151,9 @@ JSON](/appendices/#signing-json).

One-time and fallback keys are also uploaded to the homeserver using the
[`/keys/upload`](/client-server-api/#post_matrixclientv3keysupload) API. New
one-time and fallback keys are uploaded as needed.
one-time and fallback keys are uploaded as needed. Fallback keys for key
algorithms whose format is a signed JSON object should contain a property named
`fallback` with a value of `true`.

Devices must store the private part of each key they upload. They can
discard the private part of a one-time key when they receive a message
Expand Down

0 comments on commit 62c377e

Please sign in to comment.