Properly serialize public key operations when built against Botan < 3.11 - #177
Merged
Conversation
randombit
force-pushed
the
jack/pk-lock
branch
4 times, most recently
from
May 7, 2026 02:13
485fbcd to
101cf6f
Compare
All prior versions of the library had bugs affecting certain algorithms (namely XMSS, LMS, FrodoKEM, ML-KEM, and ML-DSA) which would cause incorrect computation or memory errors if multiple threads attempt to perform operations at the same time on the same key object. This lock requires std since otherwise we do not have a mutex available. So now building this crate no_std requires Botan 3.11.0 or later be used, since that's the only situation we can safely skip the lock.
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.
All prior versions of the library had bugs affecting certain algorithms (namely XMSS, LMS, FrodoKEM, ML-KEM, and ML-DSA) which would cause incorrect computation or memory errors if multiple threads attempt to perform operations at the same time on the same key object.
This lock requires std since otherwise we do not have a mutex available. So now building this crate no_std requires Botan 3.11.0 or later be used, since that's the only situation we can safely skip the lock.