4 releases
| 0.1.0-pre4.1 | Feb 19, 2026 |
|---|---|
| 0.1.0-pre4 | Nov 23, 2025 |
| 0.1.0-pre3 | Nov 20, 2025 |
| 0.1.0-pre2 | Sep 17, 2024 |
#2723 in Cryptography
64 downloads per month
Used in 2 crates
110KB
2K
SLoC
Vitamin C Traits
This crate is part of the Vitamin C framework to make cryptography code healthy.
This crate provides traits for hashing and encryption algorithms.
These are very similar to the traits provided by the digest and other crates in the RustCrypto project
with some key differences:
- The
Updatetrait takes a specific input type. This allows us to reason about the input type and its sensitivity. - The
Outputtraits are generic over the output type. This allows us to reason about the output type and its sensitivity. - All types have a trait bound of [Controlled]
constgenerics are used to specify the output size of the hash instead of GenericArray.
Async versions of some of these traits are provided in the async-traits crate.
Acknowledgements
Shoutout to Tony Arcieri, Artyom Pavlov and all the contributors to the Rust Crypto project which was the inspiration for this crate.
CipherStash
Vitamin C is brought to you by the team at CipherStash.
License: MIT
Dependencies
~2.8–3.5MB
~80K SLoC