1cfg_if::cfg_if! {
4 if #[cfg(feature = "crypto-sm")] {
5 mod sm3;
6 mod sm4;
7
8 pub use sm3::{derive_key, digest};
9 pub use sm4::{decrypt, encrypt};
10
11 pub type Digest = ::sm3::Sm3;
13 } else {
14 mod aes256;
15 mod sha256;
16
17 pub use aes256::{decrypt, encrypt};
18 pub use sha256::{derive_key, digest};
19
20 pub type Digest = ::sha2::Sha256;
22 }
23}
24
25mod password;
26mod sha1;
27
28pub use password::{
29 encrypt_hashed_password, encrypt_raw_password, verify_hashed_password, verify_raw_password,
30};
31pub use sha1::checksum;