aranya_keygen/lib.rs
1//! # Aranya Keygen
2//!
3//! Utilities for generating and managing cryptographic key bundles for Aranya applications.
4//!
5//! This crate provides functionality to:
6//! - Generate secure cryptographic key bundles containing identity, encryption, and signing keys
7//! - Store generated keys in a keystore
8//! - Retrieve public keys from a key bundle
9//!
10//! ## Key Components
11//!
12//! - [`PublicKeyBundle`]: The main structure that contains references to identity, encryption, and signing keys
13//! - [`PublicKeys`]: A structure that holds the public portions of the keys in a key bundle
14//!
15//! ## Example
16//!
17//! ```rust
18//! # use anyhow::Result;
19//! # use aranya_crypto::{Engine, KeyStore};
20//! # use aranya_keygen::PublicKeyBundle;
21//! #
22//! # fn example<CE, KS>(engine: &CE, store: &mut KS) -> Result<()>
23//! # where
24//! # CE: Engine,
25//! # KS: KeyStore,
26//! # {
27//! // Generate a new key bundle
28//! let key_bundle = PublicKeyBundle::generate(engine, store)?;
29//!
30//! // Load the public keys from the bundle
31//! let public_keys = key_bundle.public_keys(engine, store)?;
32//!
33//! // Use the public keys for operations like encryption or verification
34//! # Ok(())
35//! # }
36//! ```
37
38#![cfg_attr(docsrs, feature(doc_cfg))]
39#![warn(clippy::wildcard_imports, missing_docs)]
40
41mod keygen;
42
43pub use keygen::*;