matrix-rust-sdk icon indicating copy to clipboard operation
matrix-rust-sdk copied to clipboard

feat(widget): Send custom to-device messages in widgets in e2ee rooms

Open BillCarsonFr opened this issue 6 months ago • 1 comments

Adds the capability for widgets to send encrytped to-device messages properly.

It is getting rid of the old encrypted boolean that was used by widget to request encryption. As said by the base MSC for widget send/receive messages: Widgets should not be aware of encryption. If the widget is in an encrytped room then to-device traffic will be encrypted.

Fixes https://github.com/matrix-org/matrix-rust-sdk/issues/4859

  • [ ] Public API changes documented in changelogs (optional)

Signed-off-by:

BillCarsonFr avatar Jun 19 '25 08:06 BillCarsonFr

Codecov Report

Attention: Patch coverage is 94.54545% with 12 lines in your changes missing coverage. Please review.

Project coverage is 88.75%. Comparing base (1aa933c) to head (0291b04). Report is 113 commits behind head on main.

:white_check_mark: All tests successful. No failed tests found.

Files with missing lines Patch % Lines
crates/matrix-sdk/src/widget/matrix.rs 90.74% 1 Missing and 9 partials :warning:
...rates/matrix-sdk/src/widget/machine/from_widget.rs 66.66% 2 Missing :warning:
Additional details and impacted files
@@            Coverage Diff             @@
##             main    #5252      +/-   ##
==========================================
- Coverage   90.20%   88.75%   -1.45%     
==========================================
  Files         334      330       -4     
  Lines      105133    88866   -16267     
  Branches   105133    88866   -16267     
==========================================
- Hits        94831    78871   -15960     
+ Misses       6238     6179      -59     
+ Partials     4064     3816     -248     

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.

codecov[bot] avatar Jun 19 '25 09:06 codecov[bot]

Ok if I squash merge this?

poljar avatar Jul 01 '25 09:07 poljar

Ok if I squash merge this?

yes 👍

BillCarsonFr avatar Jul 01 '25 09:07 BillCarsonFr

Oh one thing. We should add a changelog entry, though let's do so in a separate PR.

poljar avatar Jul 01 '25 12:07 poljar

Oh one thing. We should add a changelog entry, though let's do so in a separate PR.

https://github.com/matrix-org/matrix-rust-sdk/pull/5323/files

BillCarsonFr avatar Jul 01 '25 13:07 BillCarsonFr