-
Notifications
You must be signed in to change notification settings - Fork 211
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
aead.go should import crypto/rand rather than math/rand #289
Comments
This has been sitting here a while Im going to bump it. This is very important, as said in the documentation for the
As Its also worth noting that even when you do switch to This is (unfortunately) only said in a comment on the encryption example in the golang docs.
This would mean that after some number of messages < 2^32 a keychange would be required between peers. |
The better solution, rather changing the key, would be using an algorithm to produce repetition resistant nonces. Also, here is the RFC for this, which is a bit more precise: https://tools.ietf.org/html/rfc5116#section-3.2 |
I have submitted a PR for this. There are no existing conflicts. It's a simple fix and makes the codebase more secure. |
The nonce should not be generated from a pseudo random input.
The text was updated successfully, but these errors were encountered: