crypto_core/lib.rs
1// SPDX-FileCopyrightText: Copyright © 2026 ReallyMe LLC. All rights reserved
2//
3// SPDX-License-Identifier: Apache-2.0
4
5//! Shared vocabulary types for the ReallyMe crypto workspace.
6//!
7//! This crate defines the algorithm identifiers ([`Algorithm`],
8//! [`AeadAlgorithm`], [`HashAlgorithm`]) and the typed error taxonomy
9//! ([`CryptoError`] and its failure-kind enums) that
10//! every primitive, the dispatch layer, and the FFI boundary share. It
11//! contains no cryptographic behavior — only the definitions the rest of
12//! the workspace agrees on — so that errors carry fixed, secret-free
13//! descriptors and algorithm selection is a single closed enum rather than
14//! stringly-typed.
15
16/// Algorithm identifier enums shared across the workspace.
17pub mod algorithm;
18/// Typed error taxonomy and failure-kind enums.
19pub mod error;
20
21pub use algorithm::{AeadAlgorithm, Algorithm, HashAlgorithm, MacAlgorithm};
22pub use error::{
23 AeadBackend, AeadFailureKind, ConstantTimeFailureKind, CryptoError, HkdfFailureKind, HkdfHash,
24 KdfAlgorithm, KdfFailureKind, KdfProfile, KemFailureKind, KeyAgreementFailureKind,
25 KeyWrapAlgorithm, KeyWrapFailureKind, KeyWrapOperation, MacFailureKind, MacHash,
26 RngFailureKind, RngOutputKind, SignatureBackend, SignatureFailureKind, SignatureOperation,
27};