-
Notifications
You must be signed in to change notification settings - Fork 1
Open
Labels
Description
Vitamin C uses rand (and thus rand_chacha) for the underlying random implementations.
Some of the main challenges with this approach:
randis a general purpose library for generating random data and as such cryptographically secure random number generation isn't necessarily its top priorityrand_chachadoesn't support Zeroization so there is a risk that state could remain accessible in memory allowing for potential attacks
There is a long and still ongoing discussion about replacing the current CSPRNG implementation in rand with the chacha20 crate from Rust Crypto.
Thus far it remains unresolved.
We could wait until there is a resolution to the above or consider directly using chacha20 in SafeRand and avoid the rand crate entirely.
Our needs a quite specific so this may be a reasonable approach.