Ttx/replace random nonce - #1406
Merged
Merged
Conversation
adecaro
self-requested a review
March 6, 2026 05:30
adecaro
force-pushed
the
ttx/replace-random-nonce
branch
from
March 6, 2026 05:30
50561ba to
5bcfd2a
Compare
Contributor
|
Hi @sid200727 , thanks for submitting this. Please, fix the DCO by following the relative instructions. Thanks a lot. |
sid200727
force-pushed
the
ttx/replace-random-nonce
branch
6 times, most recently
from
March 7, 2026 12:38
b9d56e4 to
f2a0720
Compare
Contributor
Author
|
Hi @adecaro, Thanks for the review and for pointing out the DCO requirement. I’ve updated the commits to include the proper sign-off. The checks are now running again. Please let me know if any further changes are needed. |
Contributor
Author
|
Hi @adecaro, It looks like the CI failure is caused by a golangci-lint download error (HTTP 502) during the install-tools step rather than an issue with the changes in this PR. Would it be possible to rerun the workflow? Thanks! |
adecaro
force-pushed
the
ttx/replace-random-nonce
branch
from
March 9, 2026 15:36
f2a0720 to
3e981c7
Compare
Contributor
|
Hi @sid200727 , yes, re-running now. I'll merge as soon as the CI gives the okay. Thanks much. |
adecaro
force-pushed
the
ttx/replace-random-nonce
branch
3 times, most recently
from
March 10, 2026 15:06
f3f595e to
6c83cc7
Compare
Signed-off-by: Siddhi Khandelwal <siddhi.200727@gmail.com>
Signed-off-by: Siddhi Khandelwal <siddhi.200727@gmail.com>
Signed-off-by: Siddhi Khandelwal <siddhi.200727@gmail.com>
adecaro
force-pushed
the
ttx/replace-random-nonce
branch
from
March 11, 2026 08:52
6c83cc7 to
ec436a6
Compare
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.
Fixes #919
This PR addresses the TODO in
GetRandomByteswithintoken/services/ttx/random.go.Previously,
rand.Readwas used to generate random bytes. However,rand.Readdoes not guarantee that the requested number of bytes will be fully populated in a single call. This could potentially result in partially filled nonces without being detected.This change replaces
rand.Readwithio.ReadFull(rand.Reader, ...), ensuring that either:This guarantees correct and complete nonce generation in
GetRandomNonce, improving reliability and aligning with Go best practices for secure randomness.