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

fix(indexeddb): correctly encode Olm session keys #1429

Merged
merged 2 commits into from
Jan 31, 2023
Merged

Conversation

richvdh
Copy link
Member

@richvdh richvdh commented Jan 31, 2023

When we store an Olm session in the database, we encode the sender key and
session ID using the store cipher. That means that we also need to encode them
when we look them up, otherwise we won't find them.

When we store an Olm session in the database, we encode the sender key and
session ID using the store cipher. That means that we also need to encode them
when we look them up, otherwise we won't find them.
@richvdh richvdh requested a review from Hywan January 31, 2023 13:44
@codecov
Copy link

codecov bot commented Jan 31, 2023

Codecov Report

Base: 73.58% // Head: 73.58% // No change to project coverage 👍

Coverage data is based on head (23157ce) compared to base (a6ad0e3).
Patch has no changes to coverable lines.

Additional details and impacted files
@@           Coverage Diff           @@
##             main    #1429   +/-   ##
=======================================
  Coverage   73.58%   73.58%           
=======================================
  Files         116      116           
  Lines       12996    12996           
=======================================
  Hits         9563     9563           
  Misses       3433     3433           

Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here.

☔ View full report at Codecov.
📢 Do you have feedback about the report comment? Let us know in this issue.

@poljar
Copy link
Contributor

poljar commented Jan 31, 2023

I was wondering why our CI didn't catch this and wondered if we indeed don't have a test for this. Seems that wasm-pack is in a sad state:

// FIXME: the tests pass, if run one by one, but run all together locally,
// as well as CI fails... see matrix-org/matrix-rust-sdk#661

Which points towards #661.

The comment and issue are as it seems talking about happier times, wasm-pack currently segfaults for me when I try to run the tests.

Copy link
Contributor

@poljar poljar left a comment

Choose a reason for hiding this comment

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

Looks good.

@poljar poljar merged commit 5dbee7d into main Jan 31, 2023
@poljar poljar deleted the rav/fix_get_sessions branch January 31, 2023 15:59
richvdh added a commit to matrix-org/matrix-js-sdk that referenced this pull request Feb 3, 2023
richvdh added a commit to matrix-org/matrix-js-sdk that referenced this pull request Feb 3, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants