element-hq / element-hq/element-web
After key storage remove/add on another client, Web fails to detect that key storage is out of sync
- Dominant language
- TypeScript
- Stars
- 13.5k
- Forks
- 2.8k
- PR merge metrics
- PR metrics pending
Description
### Steps to reproduce
1. Have 2 active devices. Web and EX, all verified with all secrets cached locally
2. On EX go to encryption settings then turn off key storage and follow the indications
3. From EX: Turn back key storage On
4. From EX: Then click on setup recovery, and follow instructions
5. Go to web
### Outcome
#### What did you expect?
Expect that Web tells me that the Recovery is out of sync
#### What happened instead?
But Web is just offering me the option to change recovery key.
(At this point web do not have the correct secret for the backup. But it has the correct cross-signing private key.)
It is possible to continue the flow
and change the recovery key (even though web do not have the correct backup key).
This can be seen if you try import from backup
As a consequence if I now try to login with that new recovery key, I loose access to backup:
```
rageshake.ts:69 SecurityManager: accessSecretStorage: error during operation Error: loadSessionBackupPrivateKeyFromSecretStorage: decryption key does not match backup info
at RustCrypto.loadSessionBackupPrivateKeyFromSecretStorage (rust-crypto.ts:1281:19)
at async SetupEncryptionStore.ts:155:25
at async doAccessSecretStorage (SecurityManager.ts:299:9)
at async withSecretStorageKeyCache (SecurityManager.ts:189:16)
at async accessSecretStorage (SecurityManager.ts:231:5)
```
### Operating system
macos
### Browser information
Chrone
### URL for webapp
app.element.io
### Application version
Element version: 1.11.91 Crypto version: Rust SDK 0.8.0 (21f7cc7), Vodozemac 0.8.1
### Homeserver
matrix.org
### Will you send logs?
Yes
Contributor guide
Assessment
This issue has not been assessed yet.