Expand description
§crypt-io
ENCRYPTION SUITE FOR RUST
AEAD encryption (ChaCha20-Poly1305, AES-256-GCM), hashing (BLAKE3, SHA-2), MAC (HMAC, BLAKE3 keyed), and KDF (HKDF, Argon2id). Algorithm-agile. RustCrypto-backed primitives with REPS discipline. Simple API. Sub-microsecond throughput.
§Design philosophy
crypt-io is a focused encryption library that wraps proven cryptographic primitives (from RustCrypto and the BLAKE3 team) with:
- A clean, ergonomic API
- Algorithm agility (switch ciphers via enum or feature flag)
- REPS-disciplined error handling and lifecycle
- Tight integration with the portfolio (mod-rand, error-forge, optional log-io/metrics-lib)
- Sub-microsecond throughput targets verified by benchmarks
crypt-io does NOT implement cryptographic primitives from scratch. The actual math comes from battle-tested upstream crates. crypt-io’s job is the integration, the API design, and the safety discipline (constant-time, zeroize, key handling).
§Scope
In scope:
- Symmetric AEAD encryption (ChaCha20-Poly1305, AES-256-GCM)
- Stream/file encryption for large data (chunked AEAD with framing)
- Hashing (BLAKE3, SHA-256, SHA-512)
- MAC (HMAC-SHA256, BLAKE3 keyed)
- KDF (HKDF for key derivation, Argon2id for password hashing)
Out of scope (use other crates):
- Random utilities -> use
mod-rand - UUID generation -> use
id-forge - Asymmetric crypto (RSA, ECDSA, Ed25519) -> deferred to separate crate
- PGP/GPG -> use
sequoia-openpgp - TLS -> use
rustls - Key storage -> use
key-vault
§Status
Early scaffolding. Public API not yet defined. See the repository
and .dev/ROADMAP.md for the milestone plan.
§License
Dual-licensed under Apache-2.0 OR MIT.
Re-exports§
pub use crate::aead::Algorithm;aead-chacha20oraead-aes-gcmpub use crate::aead::Crypt;aead-chacha20oraead-aes-gcm
Modules§
- aead
aead-chacha20oraead-aes-gcm - Authenticated encryption with associated data (AEAD).
- hash
hash-blake3orhash-sha2 - Cryptographic hash functions.
- kdf
kdf-hkdforkdf-argon2 - Key Derivation Functions (KDF).
- mac
mac-hmacormac-blake3 - Message Authentication Codes (MAC).
- stream
stream - Streaming / file encryption.
Enums§
- Error
- The error type for all
crypt-iooperations.
Constants§
- VERSION
- Crate version string, populated by Cargo at build time.
Type Aliases§
- Result
- Type alias for
core::result::Result<T, Error>.