#sha-256 #hmac #hash #hkdf #sha-2 #size-optimization

no-std hmac-sha256

A small, self-contained SHA256 and HMAC-SHA256 implementation

17 releases (9 stable)

1.1.7 Jun 14, 2023
1.1.6 Nov 29, 2022
1.1.5 Oct 25, 2022
1.1.4 Jul 1, 2022
0.1.1 Apr 10, 2019

#243 in Cryptography

Download history 22322/week @ 2023-12-11 19894/week @ 2023-12-18 7940/week @ 2023-12-25 15902/week @ 2024-01-01 21792/week @ 2024-01-08 21771/week @ 2024-01-15 24665/week @ 2024-01-22 23779/week @ 2024-01-29 21252/week @ 2024-02-05 21401/week @ 2024-02-12 25164/week @ 2024-02-19 25559/week @ 2024-02-26 29180/week @ 2024-03-04 26038/week @ 2024-03-11 26809/week @ 2024-03-18 24471/week @ 2024-03-25

107,314 downloads per month
Used in 124 crates (43 directly)

ISC license

19KB
493 lines

rust-hmac-sha256

A small, self-contained SHA256, HMAC-SHA256, and HKDF-SHA256 implementation in Rust.

Optional features:

  • traits: enable support for the Digest trait from the digest crate.
  • opt_size: enable size optimizations. Based on benchmarks, the .text section size is reduced by 75%, at the cost of approximately 16% performance.

lib.rs:

A small, self-contained SHA256 and HMAC-SHA256 implementation (C) Frank Denis <fdenis [at] fastly [dot] com>, public domain

Dependencies

~94KB