#sha-512 #hmac #hash #sha-2 #size-optimization #crypto

no-std hmac-sha512

A small, self-contained SHA512, HMAC-SHA512, SHA384 and HMAC-SHA384 implementation

16 releases (8 stable)

new 1.1.6 Dec 9, 2024
1.1.5 Jun 14, 2023
1.1.4 Nov 29, 2022
1.1.2 Jul 1, 2022
0.1.6 Jun 23, 2020

#91 in Cryptography

Download history 54485/week @ 2024-08-19 54942/week @ 2024-08-26 52355/week @ 2024-09-02 57854/week @ 2024-09-09 55139/week @ 2024-09-16 59769/week @ 2024-09-23 56857/week @ 2024-09-30 59910/week @ 2024-10-07 64057/week @ 2024-10-14 94730/week @ 2024-10-21 91879/week @ 2024-10-28 103515/week @ 2024-11-04 93045/week @ 2024-11-11 108029/week @ 2024-11-18 83832/week @ 2024-11-25 108706/week @ 2024-12-02

395,511 downloads per month
Used in 56 crates (17 directly)

ISC license

27KB
710 lines

rust-hmac-sha512

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

Also includes SHA384 and HMAC-SHA384, that are just truncated versions of SHA512 with a different IV.

Optional features:

  • traits: enable support for the Digest trait from the digest crate.
  • sha384: includes support for SHA384 and HMAC-SHA384.
  • 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 SHA512 and HMAC-SHA512 implementation (C) Frank Denis <fdenis [at] fastly [dot] com>, public domain

Dependencies

~110KB