-
Notifications
You must be signed in to change notification settings - Fork 734
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
Message keys not migrated from legacy to Rust store are not backed up after backup reset #8814
Comments
This is possible to reproduce this issue on any Element-Android client which has been updated from Element (without crypto rust) to ElementR (with crypto rust). |
On Element Web and Element iOS it seems the realm db is migrated totally. A similar behavior is needed on Android. Element iOS : Element Web : |
@giomfo do you have a plan about this issue ? It could impact some users on Element X, Element 1.6.8 and higher. |
@yostyle internal discussions are still in progress about this key migration issue |
This comment was marked as off-topic.
This comment was marked as off-topic.
This comment was marked as off-topic.
This comment was marked as off-topic.
@giomfo we can reproduce the same issue without key backup configured on the user account. I added this case in the issue description. |
Hello, while migrating all the session would fix this scenario, it will not completely fix the problem. For example in this migration case, the keys are already offloaded in the backup. The problem is that the reset backup flow that can cause key loss, and we could take action to reduce the chance of key loss by doing also something like that element-hq/element-meta#2446 |
To be clear, there are two separate problems here.
|
@yostyle According to the point 1. summarised by @richvdh above, the Reset secure backup that you did in your case 1 (step 5) should not impact the backed up keys server side. Do you know when the backup is set up in your case 1? Indeed if you set up the backup for your test after "Upgrade to Element 1.6.8" (step3), then you are mainly impacted by point2. This is the only reason, I can see, to explain the missing keys in the backup after the reset secure backup |
Steps to reproduce
case 1 (with key backup)
case 2 (without key backup)
Outcome
What did you expect?
All events should be decryptable.
What happened instead?
case 1 (with key backup)
All events are undecryptable because message keys (Megolm sessions) are not backed up.
Only message keys migrated to the Rust crypto store are backed up to the server-side key backup. Message keys that are not present in the Rust crypto store are missing in the key backup.
case 2 (without key backup)
All events are undecryptable because message keys (Megolm sessions) are not sent to the Element X session by key request feature.
Only message keys migrated to the Rust crypto store could be exchanged between sessions.
Your phone model
Pixel 8 Pro
Operating system version
Android 14
Application version and app store
No response
Homeserver
matrix.org
Will you send logs?
No
Are you willing to provide a PR?
No
The text was updated successfully, but these errors were encountered: