#hmac #pure #drbg #no-std

hmac-drbg

Pure Rust implementation of Hmac DRBG

5 unstable releases

0.3.0 Jun 15, 2020
0.2.0 Sep 26, 2019
0.1.2 Nov 8, 2017
0.1.1 Nov 8, 2017
0.1.0 Nov 7, 2017

#2351 in Algorithms

Download history 105804/week @ 2024-05-27 100678/week @ 2024-06-03 101438/week @ 2024-06-10 97318/week @ 2024-06-17 103050/week @ 2024-06-24 93151/week @ 2024-07-01 92385/week @ 2024-07-08 104462/week @ 2024-07-15 108252/week @ 2024-07-22 102237/week @ 2024-07-29 127074/week @ 2024-08-05 129920/week @ 2024-08-12 102302/week @ 2024-08-19 116835/week @ 2024-08-26 117577/week @ 2024-09-02 113478/week @ 2024-09-09

455,350 downloads per month
Used in 324 crates (7 directly)

Apache-2.0

16KB
101 lines

Hmac DRBG

Build Status License Cargo

Pure Rust Hmac DRBG implementation with support of no_std.

Usage

Add hmac-drbg = "0.1" dependency.

let mut drbg = HmacDRBG::<Sha256>::new(
    "totally random0123456789".as_bytes(),
    "secret nonce".as_bytes(),
    "my drbg".as_bytes());
assert_eq!(drbg.generate::<U32>(None).as_slice(), read_hex("018ec5f8e08c41e5ac974eb129ac297c5388ee1864324fa13d9b15cf98d9a157").unwrap().as_slice());

Dependencies

~415KB