Use AES-CTR DRBG as a Cryptographically Secure Pseudo-Random Number Generator (CSPRNG)
@sangho2 is already working on this.
Since Feb 1, 2026.
- Dominant language
- Rust
- Stars
- 2.7k
- Forks
- 144
- Avg merge
- 12h 21m
- Merged PRs (30d)
- 146
Description
As a CSPRNG, we should use AES-CTR DRBG (NIST SP 800-90A standard) which is approved by Microsoft.
Regarding entropy sources, we should access as many sources as possible like `RDSEED` (x86_64), TPM (GetRandom), and more.
Minimal feature set:
* 256-bit AES
* Entropy source (RDSEED)
* Nonce (from TPM). For now, just have a memory buffer and interface to initialize it.
* Derivation function
* No personalization
* Pass NIST test cases
There are `drbg` and `aes_ctr_drbg` crates, but we'd like to implement a simple one from scratch with the above features.
This CSPRNG replaces `litebox_platform_lvbs/src/host/lvbs_impl.rs`'s `litebox::platform::CrngProvider::fill_bytes_crng`.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Assessment
This issue has not been assessed yet.