Skip to content

MSC4268: Sharing room keys for past messages#4268

Merged
turt2live merged 15 commits into
mainfrom
rav/proposal/encrypted_history_sharing
Apr 8, 2026
Merged

MSC4268: Sharing room keys for past messages#4268
turt2live merged 15 commits into
mainfrom
rav/proposal/encrypted_history_sharing

Conversation

@richvdh

@richvdh richvdh commented Feb 24, 2025

Copy link
Copy Markdown
Member

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.

The functionality discussed here is implemented in current versions of Element Web and Element X.

Rendered

MSC checklist
FCP tickyboxes

@turt2live turt2live added A-Encryption E2EE proposal A matrix spec change proposal. Process state. A-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
Comment thread proposals/4268-encrypted-history-sharing.md
kaylendog added a commit to matrix-org/matrix-rust-sdk that referenced this pull request Dec 19, 2025
…cryption-info

feat: Add `forwarder: ForwarderInfo` to `EncryptionInfo`.

Introduces `ForwarderInfo` which which exposes information about the forwarder of the  keys with which an event was encrypted if they were shared as part of an [MSC4268](matrix-org/matrix-spec-proposals#4268) room key bundle.
kaylendog added a commit to matrix-org/matrix-sdk-crypto-wasm that referenced this pull request Jan 6, 2026
Expose information about the forwarder for events that were decrypted using a key from an [MSC4268](matrix-org/matrix-spec-proposals#4268) key bundle.

Signed-off-by: Skye Elliot <actuallyori@gmail.com>
Comment thread proposals/4268-encrypted-history-sharing.md Outdated
Comment thread proposals/4268-encrypted-history-sharing.md
@richvdh richvdh changed the title WIP: MSC4268: Sharing room keys for past messages MSC4268: Sharing room keys for past messages Jan 15, 2026
@richvdh richvdh marked this pull request as ready for review January 15, 2026 17:14
@turt2live turt2live self-requested a review January 15, 2026 17:36
@@ -0,0 +1,468 @@
# MSC4268: Sharing room keys for past messages

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

My two main concerns on this MSC are:

  • Without the ability to delete key bundles once they've been consumed by the invited user, we accumulate encrypted key material in a way which is tantamount to harvest-now-decrypt-later attacks. However, given MSC4425 (or other ephemeral MSCs) are on the radar, I'm (just about) happy to for this to progress on the understanding that we follow up afterwards rapidly with MSC4425 or similar.

  • In terms of use experience, it's really not obvious to me that the common case should be to share all possible keys with an invited user. Sometimes this will be important (e.g. knowledge transfer to a new user joining a team/org) - but sometimes it will be very undesirable even if the room has shared history viz, particularly if the history viz been changed back and forth over time. I suspect that an approach similar to the WhatsApp idiom of "how much history do you want to share with the new user? nothing? 1 msg? 100 msgs? everything?" might help with this. However: this is a client UX question and is already supported by the MSC.

So, neither of these points end up being blocking, although both make me quite uncomfortable with the proposal. I'll checkbox it to proceed, but please can we track these concerns on the Element crypto-team agenda so they're not lost.

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

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

  • Without the ability to delete key bundles once they've been consumed by the invited user, we accumulate encrypted key material in a way which is tantamount to harvest-now-decrypt-later attacks. However, given MSC4425 (or other ephemeral MSCs) are on the radar, I'm (just about) happy to for this to progress on the understanding that we follow up afterwards rapidly with MSC4425 or similar.

This is already tracked at matrix-org/matrix-rust-sdk#5113, though I would say that we'd need to deprioritise some other scheduled work for any followup to be rapid.

In terms of use experience, it's really not obvious to me that the common case should be to share all possible keys with an invited user.

My inclination on this is to deliver the implementation we have and see what feedback we get.

@mscbot

mscbot commented Apr 2, 2026

Copy link
Copy Markdown
Collaborator

🔔 This is now entering its final comment period, as per the review above. 🔔

@mscbot mscbot added final-comment-period Process state to accept, reject, or postpone an MSC. and removed proposed-final-comment-period Currently awaiting signoff of a majority of team members in order to enter the FCP. Process state. labels Apr 2, 2026
@turt2live turt2live removed the 00-weekly-pings Tracking for weekly pings in the SCT office. 00 to make it first in the labels list. label Apr 2, 2026
@turt2live turt2live moved this from Ready for FCP ticks to In FCP in Spec Core Team Workflow Apr 2, 2026
@mscbot mscbot added the unresolved-concerns This proposal has at least one outstanding concern. Process state. label Apr 7, 2026
@mscbot mscbot removed the unresolved-concerns This proposal has at least one outstanding concern. Process state. label Apr 7, 2026
@mscbot

mscbot commented Apr 7, 2026

Copy link
Copy Markdown
Collaborator

The final comment period, with a disposition to merge, as per the review above, is now complete.

@mscbot mscbot added finished-final-comment-period FCP has finished. Process state. and removed disposition-merge Process state. final-comment-period Process state to accept, reject, or postpone an MSC. labels Apr 7, 2026
@turt2live turt2live merged commit 0251b75 into main Apr 8, 2026
1 check passed
@turt2live turt2live added spec-pr-missing MSC is accepted, but missing spec PR. Process state. and removed finished-final-comment-period FCP has finished. Process state. labels Apr 8, 2026
@turt2live turt2live moved this from In FCP to Requires spec writing in Spec Core Team Workflow Apr 8, 2026
@richvdh

richvdh commented Jun 15, 2026

Copy link
Copy Markdown
Member Author

Spec PR: matrix-org/matrix-spec#2399

@tulir tulir added spec-pr-in-review A proposal which has been PR'd against the spec and is in review and removed spec-pr-missing MSC is accepted, but missing spec PR. Process state. labels Jun 15, 2026
@turt2live turt2live moved this from Requires spec writing to Requires spec PR review in Spec Core Team Workflow Jun 15, 2026
@richvdh richvdh added merged A proposal whose PR has merged into the spec! Process state. and removed spec-pr-in-review A proposal which has been PR'd against the spec and is in review labels Jun 24, 2026
@richvdh richvdh moved this from Requires spec PR review to Merged/Done in Spec Core Team Workflow Jun 24, 2026
@turt2live

Copy link
Copy Markdown
Member

Merged 🎉

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

Labels

A-Client Server Client-Server API A-Encryption E2EE kind:core MSC which is critical to the protocol's success merged A proposal whose PR has merged into the spec! Process state. proposal A matrix spec change proposal. Process state.

Projects

Status: Merged/Done

Development

Successfully merging this pull request may close these issues.