x.crypto.chacha20: mark State as public to make it a reusable thing#25449
Merged
Conversation
|
Connected to Huly®: V_0.6-26133 |
spytheman
approved these changes
Oct 6, 2025
spytheman
left a comment
Contributor
There was a problem hiding this comment.
If you expose new APIs, please also add tests for them.
Otherwise people can start to depend on them, and we would not know if/when they regress.
Contributor
Author
Okey..i would add it NB; add it in #8bca962 |
spytheman
approved these changes
Oct 7, 2025
spytheman
left a comment
Contributor
There was a problem hiding this comment.
Thank you @blackshirt 🙇🏻 .
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.
While have a working prototype implementation of
ChaCha20-Poly1305-PSIVconstruct, its used an internal ofchacha20by rewriting it as a new routine, makes it a duplicated in a lot places. I think its should be a public to make it reusable thing. See the working implementation of this construct at here.By making it accessible outside the module, its make possible to expand by new construction based on this state, like above psiv construct or possibility of this. This also mean reduces code duplication.
This patch was related to previously merged PR #25438, but comes with the changes on the
chacha20sides..Its exposes some cores of the
chacha20as public in the means of :chacha20.Stateinto user, mainly as a new building-block tool.clone,.resetand fundamental quarter round.qroundroutines.There are construct availables outside that relies on
hchacha20, but its not the concerns of this PR.Thanks
Cheers