element-hq / element-android

A Matrix collaboration client for Android.
https://element.io/
GNU Affero General Public License v3.0
3.33k stars 709 forks source link

Failed to verify signature from own device. #2455

Open zsinskri opened 3 years ago

zsinskri commented 3 years ago

Description

I have two devices (Element Desktop/Android) set up to use encryption. It mostly seems to work fine. But in one room messages send from Android appear with a white shield: "The authenticity of this encrypted message can't be guaranteed on this device." The other party sees an "unable to decrypt". Messages send from Desktop look fine both on Android and for the other party. Any ideas what might be wrong? Tips for troubleshooting?

Some further information:

Steps to reproduce

I can't reproduce this issue by creating a new room or posting into another similiar room.

I would expect my messages to be correctly signed and encrypted to all participants in the room.

Log: sent from Android. Creating this issue so that I'm able to send from Desktop.

Version information

zsinskri commented 3 years ago

New Messages send from the mentioned Android Device show up as signed and can be decrypted by the opposing party. I don't know if this is due to the update to Element Android 1.0.10 F-Droid or if time just healed all wounds (or in this case: invalid cryptographic sessions or something like that).

If you think 1.0.10 might have solved this issue, please close it.

zsinskri commented 3 years ago

It happened again, this time in a different room and with Element Android 1.0.10. I again send logs from Android.

Now it's not a DM but a group chat with 3 people. None of the recipients can see the message. Everyone in this room is verified, but one person only since yesterday. It's a room version 1 with encryption turned on only a few months ago. The recipient in the original issue is not verified, but encryption was turned on just before. That was room version 6.

Is there anything I can do to help troubleshooting?

Is there a way to move this issue to https://github.com/vector-im/element-android?

zsinskri commented 3 years ago

It just happend again (in the room of the first occurence).

/discardsession on Element Android (the device sending problematic events) fixes this issue for events sent after the new session has been created. It does not fix already sent events and I'd guess it most likely also won't prevent this issue from happening again.

(Thanks for transfering the issue! Please note that it lost it's labels during the transfer.)

Toxblh commented 2 years ago

This works to me /discardsession. Thank you