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

Pass to-device messages into rust crypto-sdk #3021

Merged
merged 1 commit into from
Jan 5, 2023

Conversation

richvdh
Copy link
Member

@richvdh richvdh commented Jan 4, 2023

This introduces a new method in SyncCryptoCallbacks. We can't just piggyback onto ClientEvent.ToDeviceEvent, because that is only emitted for successfully decrypted to-device events.

We also don't really want to hook into the EventMapper mechanism (as the current Crypto implementation does), because the rust crypto api expects the raw to-device events, rather than those that have been mangled into MatrixEvents.

Part of element-hq/element-web#21972.


This change is marked as an internal change (Task), so will not be included in the changelog.

We need a separate API, because `ClientEvent.ToDeviceEvent` is only emitted for
successfully decrypted to-device events
@richvdh richvdh force-pushed the rav/element-r/incoming_to_device branch from d5d5b6f to bd57795 Compare January 4, 2023 12:49
@richvdh richvdh marked this pull request as ready for review January 4, 2023 14:13
@richvdh richvdh requested a review from a team as a code owner January 4, 2023 14:13
Copy link
Contributor

@weeman1337 weeman1337 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM 👍

@richvdh richvdh merged commit 030abe1 into develop Jan 5, 2023
@richvdh richvdh deleted the rav/element-r/incoming_to_device branch January 5, 2023 09:54
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
T-Task Tasks for the team like planning
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants