matrix-rust-sdk icon indicating copy to clipboard operation
matrix-rust-sdk copied to clipboard

Implement MSC3061: Sharing room keys for past messages

Open BillCarsonFr opened this issue 2 years ago • 1 comments

From element-ios created by manuroe: vector-im/element-ios#4947

As per MSC3061

See https://github.com/vector-im/element-android/issues/4153

BillCarsonFr avatar Apr 11 '22 14:04 BillCarsonFr

I've created a Ruma issue for this as well: https://github.com/ruma/ruma/issues/1104

jplatte avatar Apr 28 '22 14:04 jplatte

When we do this, we should be sure not to repeat https://github.com/vector-im/element-web/issues/23778 (sending out all of the room keys at once).

richvdh avatar Nov 16 '22 17:11 richvdh

I'm aware of the flaws of the current approach, that is one of the reasons why this isn't yet implemented in the rust-sdk. A proper solution would need more time.

Thanks for reminding me.

poljar avatar Nov 17 '22 09:11 poljar

@poljar if there are other flaws it might be good to link them here, so we can make sure that they are correctly addressed in whatever solution we use for the rust-sdk?

richvdh avatar Nov 17 '22 10:11 richvdh

The main problems are:

  1. The authenticity of such keys can't be proven
  2. There's no way send over a batch of room keys, so m.forwarded_room_key is used
  3. Because of no 1 it's important to treat such keys in a special way, but no 2. makes it hard to do so.

What I proposed was to have a separate event type, which will separate the concepts and allow a batch of room keys to be sent over.

poljar avatar Nov 17 '22 10:11 poljar