| commit | 8b51b2354733100593a58be8d5421fe99f91a129 | [log] [tgz] |
|---|---|---|
| author | Josh Wu <joshwu@google.com> | Thu Jul 28 16:45:08 2022 +0800 |
| committer | Henri Chataing <henrichataing@google.com> | Wed Oct 19 17:54:20 2022 +0000 |
| tree | a0287a9fd3e0e6af4e07390dfe87baa6b32d7ace | |
| parent | 3eaac1d03750a3fede31fa0cbbf6d41214638bc6 [diff] |
Make crate vendor available Test: m Bug: 235777894 Bug: 245578454 Ignore-AOSP-First: cherry-pick from AOSP Merged-In: Ia59d0d8bc9e840b47aa443acc6e830929f03e56c Change-Id: Ia59d0d8bc9e840b47aa443acc6e830929f03e56c (cherry picked from commit e35d4848d13e612bdaf9a505a5029820c86e082c)
A cryptographically secure random number generator that uses the ChaCha algorithm.
ChaCha is a stream cipher designed by Daniel J. Bernstein[^1], that we use as an RNG. It is an improved variant of the Salsa20 cipher family, which was selected as one of the “stream ciphers suitable for widespread adoption” by eSTREAM[^2].
The RNGs provided by this crate are implemented via the fast stream ciphers of the c2-chacha crate.
Links:
[^1]: D. J. Bernstein, ChaCha, a variant of Salsa20
[^2]: eSTREAM: the ECRYPT Stream Cipher Project
rand_chacha is no_std compatible when disabling default features; the std feature can be explicitly required to re-enable std support. Using std allows detection of CPU features and thus better optimisation.
rand_chacha is distributed under the terms of both the MIT license and the Apache License (Version 2.0).
See LICENSE-APACHE and LICENSE-MIT, and COPYRIGHT for details.