Skip to content
This repository has been archived by the owner on Apr 26, 2024. It is now read-only.

Log when we see a to device message which contains unknown devices #6671

Closed
erikjohnston opened this issue Jan 9, 2020 · 1 comment
Closed
Assignees
Labels
A-Logging Synapse's logs (structured or otherwise). Not metrics.

Comments

@erikjohnston
Copy link
Member

When we receive a to device message we should look at all the device IDs and device keys in it to make sure they match what the server expects. If they don't match then a device list on somewhere is out of sync, and we should log to aid debugging.

(We may also want to think about proactively trying to repair the problem, but that is a next step).

e.g. a m.room.encrypted message with an algorithm: m.olm.v1.curve25519-aes-sha2 has:

  1. A user_id and sender_key which we should have in our device_lists_remote_cache (if populated).
  2. The keys of content.ciphertext should match device keys of other users in the room (and so should be in device_lists_remote_cache or e2e_device_keys). If we don't recognise any other device keys then it may mean that our device_lists_remote_cache is out of date for a user in the room, or if there are device keys missing for our local users then the remote server's/client's device list may be out of date.
@erikjohnston erikjohnston self-assigned this Jan 9, 2020
@neilisfragile neilisfragile added A-Logging Synapse's logs (structured or otherwise). Not metrics. p1 labels Jan 14, 2020
@erikjohnston
Copy link
Member Author

Parts of this was done as part of #6776 etc

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
A-Logging Synapse's logs (structured or otherwise). Not metrics.
Projects
None yet
Development

No branches or pull requests

2 participants