#keccak #hash #hashing #hasher #green #keeps #prime

bin+lib keccak_prime

The hashing algorithm that keeps your blockchain green

1 unstable release

0.1.0 Nov 9, 2023

#13 in #keeps

Download history 8/week @ 2024-02-15 23/week @ 2024-02-22 19/week @ 2024-02-29 8/week @ 2024-03-07 6/week @ 2024-03-14 33/week @ 2024-03-28 27/week @ 2024-04-04 7/week @ 2024-04-11

67 downloads per month

MIT license

67KB
1.5K SLoC

Keccak Prime

The hashing algorithm that keeps your PoW blockchain green.

To make use of CPU acceleration for AES, provide the following compilation flags:

RUSTFLAGS="-Ctarget-cpu=sandybridge -Ctarget-feature=+aes,+sse2,+sse4.1,+ssse3"

lib.rs:

Keccak derived functions specified in FIPS-202, SP800-185 and KangarooTwelve.

Example

#
let input_a = b"hello world";
let input_b = b"!";
let mut output = [0u8; 32];
hasher.update(input_a);
hasher.update(input_b);
hasher.finalize(&mut output);

Credits

License

CC0. Attribution kindly requested. Blame taken too, but not liability.

Dependencies

~1.5MB
~27K SLoC