pub fn sha256(value: &[u8]) -> Vec<u8> ⓘ
Expand description
Hashes the random sequence of bytes using sha256.
§Examples
use near_sdk::env::sha256;
use hex;
assert_eq!(
sha256(b"The phrase that will be hashed"),
hex::decode("7fc38bc74a0d0e592d2b8381839adc2649007d5bca11f92eeddef78681b4e3a3").expect("Decoding failed")
);