Debian Codegraph @

debian/rust-vendor/sm3/src/lib.rs

raw
1 #![no_std]
2 #![doc = include_str!("../README.md")]
3 #![doc(
4 html_logo_url = "https://raw.githubusercontent.com/RustCrypto/media/6ee8e381/logo.svg",
5 html_favicon_url = "https://raw.githubusercontent.com/RustCrypto/media/6ee8e381/logo.svg"
6 )]
7 #![cfg_attr(docsrs, feature(doc_cfg))]
8 #![forbid(unsafe_code)]
9 #![warn(missing_docs, unreachable_pub)]
10
11 pub use digest::{self, Digest};
12
13 /// Block-level types
14 pub mod block_api;
15 mod compress;
16 mod consts;
17
18 pub use block_api::Sm3Core;
19
20 digest::buffer_fixed!(
21 /// ShangMi 3 (SM3) hasher.
22 pub struct Sm3(block_api::Sm3Core);
23 // Note that we use the GM/T OID here.
24 // SM3 has also an alternative ISO OID assigned to it.
25 oid: "1.2.156.10197.1.401";
26 impl: FixedHashTraits;
27 );