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

Unify getentropy-based implementations #418

Merged
merged 1 commit into from May 2, 2024

Conversation

josephlr
Copy link
Member

@josephlr josephlr commented May 2, 2024

This is similar to what we did for getrandom.rs, and makes switching just Solaris to getentropy easier.

Signed-off-by: Joe Richey <joerichey@google.com>
Copy link
Member

@newpavlov newpavlov left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This adds 256-byte chunking for Emscripten, which, strictly speaking, is not needed, but I guess it's fine.

@josephlr
Copy link
Member Author

josephlr commented May 2, 2024

This adds 256-byte chunking for Emscripten, which, strictly speaking, is not needed, but I guess it's fine.

Ya I thought about special-casing this, but I think the fact that emscripten's getentropy works with buffers longer than 256 bytes is undocumented, so maybe it's not the best that we were depending on it.

@josephlr josephlr merged commit 20c2213 into rust-random:master May 2, 2024
51 checks passed
@josephlr josephlr deleted the getentropy branch May 2, 2024 08:53
@newpavlov newpavlov mentioned this pull request May 5, 2024
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.

None yet

2 participants