#![forbid(unsafe_code)]
#![deny(missing_docs)]
pub mod b64;
pub mod box_seal;
mod ecc;
pub mod ed25519;
pub mod error;
pub mod hash;
pub mod hkdf;
pub mod hybrid;
pub mod kdf;
pub mod keys;
pub mod mac;
pub mod recovery;
pub mod seal;
pub mod secretbox;
pub mod sign;
#[cfg(not(target_arch = "wasm32"))]
pub mod stack;
pub mod suite;
pub mod vrf;
pub mod vrf_p256;
#[cfg(target_arch = "wasm32")]
pub mod wasm;
pub use error::CryptoError;
pub use b64::parse_salt_from_key_hash;
pub use box_seal::{box_seal, box_seal_open};
pub use ed25519::{
ED25519_PUBLIC_KEY_LEN, ED25519_SEED_LEN, ED25519_SIGNATURE_LEN, ed25519_generate_keypair,
ed25519_public_key, ed25519_sign, ed25519_verify,
};
pub use hash::{sha3_256, sha3_512, sha3_512_with_context, sha256, sha512};
pub use hkdf::{HASH_LEN as HKDF_SHA512_HASH_LEN, hkdf_sha512};
pub use hybrid::{
HybridKeyPair, SecurityLevel, generate_hybrid_keypair, generate_hybrid_keypair_512,
generate_hybrid_keypair_1024, generate_hybrid_keypair_suite,
generate_hybrid_keypair_with_level, hybrid_open, hybrid_open_with_context, hybrid_seal,
hybrid_seal_512, hybrid_seal_1024, hybrid_seal_suite, hybrid_seal_suite_with_context,
hybrid_seal_with_level, is_hybrid_ciphertext,
};
pub use kdf::derive_session_key;
pub use keys::{
KeyPair, decrypt_private_key, encrypt_private_key, generate_key, generate_keypair,
generate_salt,
};
pub use mac::{HMAC_SHA256_LEN, hmac_sha256};
pub use recovery::{
RecoveryKey, decrypt_private_key_with_recovery, encrypt_private_key_for_recovery,
generate_recovery_key, recovery_key_to_secret,
};
pub use seal::{
seal_for_user, seal_for_user_with_level, seal_for_user_with_suite, unseal_from_user,
};
pub use secretbox::{
decrypt_secretbox, decrypt_secretbox_to_string, encrypt_secretbox, encrypt_secretbox_string,
};
pub use sign::{
HybridSignatureKeyPair, SIGN_CONTEXT_V1, SignatureLevel, derive_public_key,
generate_signing_keypair, generate_signing_keypair_44, generate_signing_keypair_87,
generate_signing_keypair_suite, generate_signing_keypair_with_level, sign, signature_posture,
signature_posture_from_signature, verify,
};
#[cfg(not(target_arch = "wasm32"))]
pub use stack::{RECOMMENDED_SIGNING_STACK_BYTES, on_signing_stack};
pub use suite::{SEAL_CONTEXT_V1, Suite};
pub use vrf::{
ECVRF_EDWARDS25519_SHA512_TAI_SUITE, ECVRF_OUTPUT_LEN, ECVRF_PROOF_LEN, ECVRF_PUBLIC_KEY_LEN,
ECVRF_SECRET_KEY_LEN, ecvrf_generate_keypair, ecvrf_proof_to_hash, ecvrf_prove,
ecvrf_public_key, ecvrf_verify,
};
pub use vrf_p256::{
ECVRF_P256_OUTPUT_LEN, ECVRF_P256_PROOF_LEN, ECVRF_P256_PUBLIC_KEY_LEN,
ECVRF_P256_SECRET_KEY_LEN, ECVRF_P256_SHA256_TAI_SUITE, ecvrf_p256_generate_keypair,
ecvrf_p256_proof_to_hash, ecvrf_p256_prove, ecvrf_p256_public_key, ecvrf_p256_verify,
};