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

Unable to decrypt old message with cross device verification #23374

Closed
B4dM4n opened this issue Sep 29, 2022 · 1 comment · Fixed by matrix-org/matrix-js-sdk#2730
Closed

Unable to decrypt old message with cross device verification #23374

B4dM4n opened this issue Sep 29, 2022 · 1 comment · Fixed by matrix-org/matrix-js-sdk#2730
Labels
A-E2EE O-Occasional Affects or can be seen by some users regularly or most users rarely S-Major Severely degrades major functionality or product features, with no satisfactory workaround T-Defect

Comments

@B4dM4n
Copy link

B4dM4n commented Sep 29, 2022

Steps to reproduce

  1. Have one verified session (latest Element Android/Web/Desktop tested) open
  2. Sign in a new session on another device/browser session
  3. Select "verify with another device" to verify the session
  4. Use the client from 1. with either QR-Code or Emoji verification

Outcome

What did you expect?

Old messages in encrypted rooms, which are already decrypted on client 1., can be derypted and read on the new session

What happened instead?

All messages show Unable to decrypt: The sender's device has not sent us the keys for this message.

Workaround

Using the security key to verify the new session allows to decrypt all messages

Operating system

NixOS

Browser information

Chromium 105.0.5195.125

URL for webapp

app.element.io

Application version

1.11.8

Homeserver

Synapse v1.68.0

Will you send logs?

Yes

@cxr6548
Copy link

cxr6548 commented Oct 2, 2022

I'm also running to this issue on my Dendrite 0.10.1 homeserver. Only on user is affected and they are running element on android.

When viewing source: Decrypted

{
  "type": "m.room.message",
  "content": {
    "msgtype": "m.bad.encrypted",
    "body": "** Unable to decrypt: The secure channel with the sender was corrupted. Trying to create a new secure channel and re-requesting the keys. **"
  }
}

and original event source:

{
  "content": {
    "algorithm": "m.megolm.v1.aes-sha2",
    "ciphertext": "AwgAEoABut2YGIQWLDOz3Mb9K95rlydAaWp86KrOCIE7cLkf+ddI71Jcoo8qDa0IhFYZydKQ0UQvb3oJSVbi36PWv6rw9LKTp+cL7HsGKtpaVD4zt0cgd5QRxpFUsC97JJRjvCafuzHwq6KxVSBP4p1N1daqg90mT0OYxp6RZ9g/AQ9VuhwBlSeuJPPXR3B6SWaExjL7EP7DF1pPb4SPek6DOjCAQhBPvTxAt2EiSVifE9SGj0JeWiSXKORNOgihrUPCOUy/bYFhEf6nCQA",
    "device_id": "-1AjXBS3",
    "sender_key": "Vjc9Dmjzqt70M+ED1g2KzJTmirDc2Pmv6ktKVFAchgk",
    "session_id": "hBWmDgZ/aWG5dXgH2C0ZgzPTBdhfgDD9BzTR+R67j3E"
  },
  "event_id": "$XPPOB14D2eAvwhOpCWHA7SDdTmUV-30Qg0XHIl3lD_Y",
  "origin_server_ts": 1664677271050,
  "sender": "@user:mydomain.com",
  "type": "m.room.encrypted",
  "room_id": "!Ubzd0VN5WKGQ8D5U:mydomain.com"
}

Terminating their account and giving them a new one did not help. Only this person is affected so far. I can private chat them but they cannot participate in encrypted rooms.

@justjanne justjanne added S-Major Severely degrades major functionality or product features, with no satisfactory workaround A-E2EE O-Occasional Affects or can be seen by some users regularly or most users rarely labels Oct 4, 2022
odelcroi added a commit to tchapgouv/tchap-web-v4 that referenced this issue Oct 6, 2022
su-ex added a commit to SchildiChat/matrix-js-sdk that referenced this issue Oct 29, 2022
* Changes the `uploadContent` API, kills off `request` and `browser-request` in favour of `fetch`, removed callback support on a lot of the methods, adds a lot of tests. ([\matrix-org#2719](matrix-org#2719)). Fixes matrix-org#2415 and matrix-org#801.
* Remove deprecated `m.room.aliases` references ([\matrix-org#2759](matrix-org#2759)). Fixes element-hq/element-web#12680.
* Remove node-specific crypto bits, use Node 16's WebCrypto ([\matrix-org#2762](matrix-org#2762)). Fixes matrix-org#2760.
* Export types for MatrixEvent and Room emitted events, and make event handler map types stricter ([\matrix-org#2750](matrix-org#2750)). Contributed by @stas-demydiuk.
* Use even more stable calls to `/room_keys` ([\matrix-org#2746](matrix-org#2746)).
* Upgrade to Olm 3.2.13 which has been repackaged to support Node 18 ([\matrix-org#2744](matrix-org#2744)).
* Fix `power_level_content_override` type ([\matrix-org#2741](matrix-org#2741)).
* Add custom notification handling for MSC3401 call events  ([\matrix-org#2720](matrix-org#2720)).
* Add support for unread thread notifications ([\matrix-org#2726](matrix-org#2726)).
* Load Thread List with server-side assistance (MSC3856) ([\matrix-org#2602](matrix-org#2602)).
* Use stable calls to `/room_keys` ([\matrix-org#2729](matrix-org#2729)). Fixes element-hq/element-web#22839.
* Fix POST data not being passed for registerWithIdentityServer ([\matrix-org#2769](matrix-org#2769)). Fixes matrix-org/element-web-rageshakes#16206.
* Fix IdentityPrefix.V2 containing spurious `/api` ([\matrix-org#2761](matrix-org#2761)). Fixes element-hq/element-web#23505.
* Always send back an httpStatus property if one is known ([\matrix-org#2753](matrix-org#2753)).
* Check for AbortError, not any generic connection error, to avoid tightlooping ([\matrix-org#2752](matrix-org#2752)).
* Correct the dir parameter of MSC3715 ([\matrix-org#2745](matrix-org#2745)). Contributed by @dhenneke.
* Fix sync init when thread unread notif is not supported ([\matrix-org#2739](matrix-org#2739)). Fixes element-hq/element-web#23435.
* Use the correct sender key when checking shared secret ([\matrix-org#2730](matrix-org#2730)). Fixes element-hq/element-web#23374.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-E2EE O-Occasional Affects or can be seen by some users regularly or most users rarely S-Major Severely degrades major functionality or product features, with no satisfactory workaround T-Defect
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants