Cargo Features
[dependencies]
cocoon = { version = "0.4.3", default-features = false, features = ["std", "alloc", "getrandom", "thiserror"] }
- default = std
-
Enables
std
feature by default. - std default = alloc
-
Enables all features, including support of simplified Cocoon API, using
rand::thread_rng
, and API related tostd::io
: wrap to writer, unwrap from reader. - alloc std
-
Enables
Vec
container. Can be used withoutstd
crate (in "no std" build).Enables alloc of chacha20poly1305
- getrandom
-
Enables support of Cocoon::from_entropy() which gets random bytes from OsRng.
Features from optional dependencies
- thiserror implicit feature
-
Enables thiserror ^1.0.61
thiserror:
derive(Error)