-
Notifications
You must be signed in to change notification settings - Fork 14
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Users joining a private room within a space via "restricted" join rule have no way of accessing (encrypted) history #646
Comments
@BillCarsonFr points out that another option could be to store the keys for the rooms in the space in an online key backup, and then gossip the key for that backup to users who are invited to the space. This obviously defeats any post-compromise security, but given the whole point here is to share history enthusiastically with members of the space, PCS is pretty irrelevant for this use case. |
Rough description: It would use the same API as for A space admin would then create a new symetric backup version signed by him and store the Then when someone invites a user to the space he then gossip the symetric backup key (encrypted When a user joins a room restricted to a space, he can check for a backup on that space using the |
The only problem i can see with using online backup for this purpose is that it might freak out deployments who are allergic to online backup (given the fact it stores all their keys behind a single secret - e.g. Tchap). For them, we could perhaps do the "send all keys for all rooms to everyone in the space" trick (option 2 above)... or just say "sorry, no history in these rooms unless your deployment supports online backup" |
At the very least, the option "let users see past history" should only be available on setups and rooms where this setting has an effect. |
Added a proposal to solve this by requesting manually inspired by the knocking join rule |
Lots of discussion in an internal Element room, which may be useful to extract conclusions from: https://matrix.to/#/!ZCWYLfAKXolsPWObuZ:matrix.org/$0EQlzqgHoTmJzE8qxHhzzop1LihT7-ArlZG4MIdBtAw?via=matrix.org&via=element.io&via=one.ems.host |
One option for making this scale better would be to reuse megolm sessions across rooms within a given space. After all, the main reason we use different megolm sessions for each room is because we expect the audience list for each room to be different. If the audience list is actually the same (all space members), then maybe we don't really need a separate megolm session per room. That said, you'd still end up with a lot of megolm keys you never need.
It's very hard to see how this would interact with users/devices leaving the space (and therefore, presumably, not being entitled to access to further messages). Presumably, someone (the space admin? but what if they are offline?) would need to create a new shared key backup, and share the keys to that to all still-extant space members. |
As a variant on the online-backup solution: if we manage to solve the problem of securely generating and sharing a shared "backup" key among all the clients in the space ... rather than using it to encrypt megolm keys, could we use it to encrypt messages directly? In other words, rather than encrypting messages with megolm: encrypt and MAC them with something derived from the shared key, and then sign them with a separate ed25519 key (which can either be shared over 1:1 Olm channels, or published in the clear, depending on where we want to end up on the deniability-vs-authenticated-history scale). |
Steps to reproduce
Outcome
What did you expect?
If the room's history visibility is shared, newly joined users expect to be able to read history.
What happened instead?
Newly joined users have no way of reading history (unless they send keyshare requests to the original sending devices, but that will require those devices to still exist and be online and running in order to service the requests). Therefore the history will be suppressed.
Thoughts
This is a major problem for knowledge exchange within private spaces, as in something like Slack or Rocket.Chat you'd expect to see history when dipping into a channel in a given workspace. Some people workaround this by not enabling encryption on private rooms (ugh), but given the default behaviour is to encrypt private rooms, this ends up with a really bad experience of valuable history/context/knowledge being invisible to new members.
Another workaround is to manually export chat history and share as ZIPs within the room when new people join, but this is obviously a horrible hack.
Possible solutions
I think the best bet might be option 2, but it's not ideal; other suggestions welcome.
The text was updated successfully, but these errors were encountered: