1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
//! # Citadel Cryptographic Core (citadel_crypt)
//!
//! A comprehensive cryptographic framework providing secure communication primitives for the Citadel Protocol.
//! This crate serves as the cryptographic backbone, implementing various security mechanisms including
//! post-quantum cryptography, perfect forward secrecy, and anti-replay protection.
//!
//! ## Features
//!
//! * **Post-Quantum Security**: Integration with quantum-resistant cryptographic algorithms
//! * **Perfect Forward Secrecy**: Implemented through stacked ratchet mechanisms
//! * **Secure Memory Management**: Zero-copy secure buffer implementations for sensitive data
//! * **Entropy Management**: Sophisticated entropy banking system for secure key derivation
//! * **Network Security**: Packet vectorization and port scrambling for enhanced communication security
//! * **FCM (Forward Chain Messaging)**: Cryptographic primitives for secure message forwarding
//! * **Argon2 Integration**: Memory-hard key derivation with auto-tuning capabilities
//!
//! ## Important Notes
//!
//! * All cryptographic operations are designed to be thread-safe and memory-efficient
//! * The crate implements defense-in-depth with multiple layers of security
//! * Zero-copy operations are used where possible to minimize exposure of sensitive data
//! * Automatic memory zeroing is implemented for sensitive data structures
//!
//! ## Related Components
//!
//! * `citadel_pqcrypto`: Post-quantum cryptographic primitives
//! * `citadel_types`: Common type definitions used across the Citadel Protocol
//! * `citadel_wire`: Network protocol implementation
//!
/// Convenient imports for external use
/// For argon-related functionality
/// An abstraction binding the entropy_bank and the PQC
/// Error type
/// For endowing packets with coordinates
/// Contains the cryptographic primitives for handling FCM interactions on the network
/// Contains the subroutines for network-related functionality
/// For secure byte handling
/// Provides entropy_bank management, update, and versioning. This is what's exposed to the citadel_user api. The entropy_banks themselves are abstracted beneath
/// For secure messaging with concurrent ratcheting operations