matrix-org/matrix-hookshot

unable to decrypt message on new but verified user session

Closed this issue · 2 comments

Messages sent by the Hookshot bot are consistently unreadable by some users due to decryption issues, displaying only "Unable to decrypt message." It can take up to two days before affected users can successfully decrypt and read the messages.

This issue occurs exclusively with messages from the Hookshot bot.

Is there a way to keep the bot online for an extended period to ensure successful key exchange?

Steps to reproduce:

  • User: Having a active session.
  • Inviting Hookshot Bot and create web hook.
  • Web Hook: sends messages: All Fine
  • User: (delete session or app and/or) creates a new session and verifies this session
  • Web Hook: sends messages: User always get's "unable to decrypt message"

image

Decrypted event:

{
  "type": "m.room.message",
  "content": {
    "msgtype": "m.bad.encrypted",
    "body": "** Unable to decrypt: DecryptionError: The sender's device has not sent us the keys for this message. **"
  }
}

original event:

{
  "type": "m.room.encrypted",
  "sender": "@_webhookhs_prometheus:netresearch.de",
  "content": {
    "algorithm": "m.megolm.v1.aes-sha2",
    "ciphertext": "Awg...OpAY",
    "device_id": "BOPKPMWUPZ",
    "sender_key": "pXN***N0Q",
    "session_id": "iFN***sOQ"
  },
  "origin_server_ts": 1731919570589,
  "unsigned": {
    "membership": "join",
    "age": 62
  },
  "event_id": "$Ht***-a4A",
  "room_id": "!***:netresearch.de"
}

Fix: drop web hook and recreate a new hook. User is able to read messages again ... until he is required to use/create a new session.

Problem seems solved with release 6.0.0

Thank You.

I'm fairly certain it is not solved.