Skip to content
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

Epic: Users should not see UTDs for messages they are not supposed to be able to read #2312

Closed
2 of 3 tasks
BillCarsonFr opened this issue Feb 28, 2024 · 2 comments
Closed
2 of 3 tasks
Labels
T-Epic Issue is at Epic level Team: Crypto

Comments

@BillCarsonFr
Copy link
Member

BillCarsonFr commented Feb 28, 2024

Abstract

There are cases when messages cannot be decrypted by a client, and it is expected/known that it can't.

Currently clients will display these messages, and display them as errors: unable to decrypt messages.

In some cases, these UTDs (Unable To Decrypt) can be resolved (decrypted) if the user performs some action.

The goal is to identify these type of UTDs and see if they could be hidden to the user until the action that could resolve them is performed.

Definition

A UTD is expected when a message which keys were not supposed to be (or couldn't be) shared with your current device is received.

When sending a message, the client checks for all devices in the room, then sends them the Megolm key to decrypt the message. Therefore, for example if the current device was not in the room at that point, it will create an expected UTD.

Notice that we are talking here about a device joining a room, not a user joining a room. Devices have their own life time, and is different from the user life time.

Scenarios creating avoidable UTDs:

Expected UTDs can sometimes be fixed

  • If you have enabled server side key backup, you will be able to recover history (since the point you joined/got invited to the room). If the backup has been fully imported, in best case the UTDs will be resolved (there are cases were the backup could be missing some keys).

  • In e2e rooms that allows to access pre-join/pre-invite history, the UTD wont fix unless MSC3061 is supported by both the person that invited you, and your current device. It will also only work if you are invited, and not if you join by yourself (space restricted rooms)

  • It is also possible that a user manually imports room keys from a file. This could fix any kind of UTDs (could be possible that an other users shares keys to you in that way)

image

Breakdown

Tasks

Preview Give feedback
  1. 3 of 3
    Team: Crypto
    richvdh
  2. BillCarsonFr andybalaam
    richvdh uhoreg
@BillCarsonFr BillCarsonFr added T-Epic Issue is at Epic level Team: Crypto labels Feb 28, 2024
@BillCarsonFr
Copy link
Member Author

BillCarsonFr commented Feb 28, 2024

I might heavily update this issue, as it looks like I end up writing every thing we know about that could cause UTD. Instead of things we know will be in UTD until the session has been properly verified.

Updated the issue

@BillCarsonFr BillCarsonFr changed the title Epic: Expected UTDs Epic: Avoidable UTDs Feb 29, 2024
@BillCarsonFr BillCarsonFr changed the title Epic: Avoidable UTDs Epic: Users should not see UTDs for messages they are not supposed to be able to read Feb 29, 2024
@richvdh
Copy link
Member

richvdh commented Jun 20, 2024

Closing this, because the two sub-issues have been resolved

@richvdh richvdh closed this as completed Jun 20, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
T-Epic Issue is at Epic level Team: Crypto
Projects
None yet
Development

No branches or pull requests

2 participants