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

Update fallback management (with unpublished) #1329

Draft
wants to merge 1 commit into
base: develop
Choose a base branch
from

Conversation

BillCarsonFr
Copy link
Member

@BillCarsonFr BillCarsonFr commented Dec 17, 2021

Depends on https://gitlab.matrix.org/matrix-org/olm/-/merge_requests/48

OlmKit now manage the published/unpublished status of fallback keys.
So now #markOneTimeKeysAsPublished will also mark any unpublished fallback key as published.
As a consequence we must upload unpublished fallback key at the same time we do uplaod OTK.
We should also call forget fallback key once we are reasonably certain that you will not receive any more messages that uses the old fallback key (via forgetFallbackKey)

@manuroe Letting this as a Draft, because there is a race issue where I receveive an old sync response telling that I need to generate a new fallback key, while I just uploaded it. Causing the SDK to over generate and then loose a fallback key (potentially creating a fail to establish channel)

Also where should I store the lastFallbackUploadTime, I am using UserDefault but not sure I shouldn't be using some existing mecanism

Pull Request Checklist

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.

1 participant