Function exonum::crypto::hash [] [src]

pub fn hash(data: &[u8]) -> Hash

Calculates an SHA-256 hash digest of a bytes slice.

Examples

use exonum::crypto;

let data = [1, 2, 3];
let hash = crypto::hash(&data);