#sha2 #hash

pretty-sha2

A wrapper for sha2 library to get hash string with [0-9] & [a-z] & [A-Z] alphabet

5 releases

Uses new Rust 2021

0.1.4 Nov 16, 2022
0.1.3 Nov 16, 2022
0.1.2 Nov 16, 2022
0.1.1 Nov 16, 2022
0.1.0 Nov 16, 2022

#500 in Cryptography

Download history 136/week @ 2022-11-16

136 downloads per month

MPL-2.0 license

8KB

A wrapper for sha2 library to get hash string with [0-9] & [a-z] & [A-Z] alphabet


Code example

fn main() {
  let some_input = "some string";
  let hashed = pretty_sha2::sha512::gen(some_input);
  let random_hash = pretty_sha2::sha512::gen_rnd();
  println!("{}", hashed); // KMW1haL81kP6KR4vwpQoxRngltgmiEoXIYATz6klwmvmIx62mulnQrHscoAy29k7
  println!("{}", random_hash)
}

Dependencies

~365KB