Skip to content

Conversation

@richvdh
Copy link
Member

@richvdh richvdh commented Feb 24, 2025

A proposal for sharing the keys to existing room messages when inviting someone to a room.

This reintroduces the functionality previously proposed in MSC3061.

Conflict of Interest declaration: I am employed by Element. This MSC was written as part of my work on the Element Cryptography team.

Rendered

@turt2live turt2live added e2e proposal A matrix spec change proposal client-server Client-Server API kind:core MSC which is critical to the protocol's success needs-implementation This MSC does not have a qualifying implementation for the SCT to review. The MSC cannot enter FCP. labels Feb 24, 2025
@richvdh

This comment was marked as resolved.

poljar added a commit to ruma/ruma that referenced this pull request Jun 27, 2025
poljar added a commit to ruma/ruma that referenced this pull request Jun 27, 2025
zecakeh pushed a commit to ruma/ruma that referenced this pull request Jun 27, 2025
zecakeh pushed a commit to ruma/ruma that referenced this pull request Jul 3, 2025

### Room key bundle format

When Alice is about to invite Bob to a room, she first assembles a "room key

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Does this imply that clients should have all the keys for the room locally for the room at the time of the invite?

I'm thinking of a client that doesn't download it's complete key storage on login, but instead lazily requests keys as needed from it's homeserver.

Should we be suggesting that clients should download their complete key storage at login? Or that clients that don't download all their keys at login should download all their keys prior to inviting someone using the existing GET /_matrix/client/v3/room_keys/keys/{roomId} endpoint?

Additionally, clients may need to defer sending the invite if they're currently catching up on a backlog of to_device events, and there might be a race where recent keys aren't available to the client when they would like to make the invite.

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I should avoid making comments mid-Matrix Conference presentations, lest they be answered in later slides.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

lol 😁 For those following at home, the answer to both questions is "yes", and this might be worth calling out in the text of the MSC

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

(FWIW we do think that clients should be downloading their complete key storage at login, to guard against key loss due to a storage reset operation: element-hq/element-meta#2446)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

client-server Client-Server API e2e kind:core MSC which is critical to the protocol's success needs-implementation This MSC does not have a qualifying implementation for the SCT to review. The MSC cannot enter FCP. proposal A matrix spec change proposal

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants