Repository navigation
Conversation
Decoding a public key from its ed25519 form converted it to its curve25519 form right away, which needs a field inversion. For OMEMO 2 sessions, the identity keys are stored in their ed25519 form, so each loaded session record converted two keys per session state, also the archived ones. Encrypting or decrypting a message never uses them in their curve25519 form, though. The curve25519 form is computed on first use now. Loading and storing a session record without archived states takes 0.7 us instead of 22.5 us, and with 40 archived states 34 us instead of 695 us.
lnjX
marked this pull request as ready for review
November 21, 2026 17:33
Not up to standards ⛔
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Decoding a public key from its ed25519 form converted it to its curve25519 form and that needs a field inversion and is rather slow.
Loading and storing a session record took 22.5 us without archived states and 695 us with 40. Now it takes 0.7 us and 34 us.