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

Avoid crypto random APIs where pseudo-random will do #693

Merged
merged 2 commits into from Oct 3, 2023

Conversation

9at8
Copy link
Contributor

@9at8 9at8 commented Oct 2, 2023

No description provided.

@AArnott
Copy link
Collaborator

AArnott commented Oct 2, 2023

Why?

These random bytes are not for an operation that requires cryptographically secure random data. We just need a strong probability of a different random number than the other party so we can establish asymetry.

@9at8
Copy link
Contributor Author

9at8 commented Oct 2, 2023

We talked about this over teams. We came to the conclusion that we do not need cryptographically secure random data, so the added complexity of supporting both browser and node is not worth it. This is why we decided to go with Math.random(), which is available on both platforms.

@AArnott AArnott changed the title Use browser crypto if available Avoid crypto random APIs where pseudo-random will do Oct 2, 2023
@AArnott
Copy link
Collaborator

AArnott commented Oct 2, 2023

Do you want to rebase and retarget against v2.10 for a faster stable release?

@9at8 9at8 changed the base branch from main to v2.10 October 3, 2023 00:00
@AArnott AArnott merged commit 942a9e3 into dotnet:v2.10 Oct 3, 2023
7 checks passed
@9at8 9at8 deleted the patch-1 branch October 3, 2023 00:42
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