Skip to main content

Crate apfsds_crypto

Crate apfsds_crypto 

Source
Expand description

APFSDS Crypto - Encryption, signing, and key management

This crate provides:

  • Ed25519 key generation and signing (legacy)
  • ML-DSA-65 (Dilithium3) post-quantum signatures
  • X25519 ECDH key exchange (legacy)
  • ML-KEM-768 (Kyber) post-quantum key exchange
  • AES-256-GCM encryption/decryption
  • HMAC-SHA256 with constant-time comparison
  • Replay cache for nonce deduplication

Structs§

Aes256GcmCipher
AES-256-GCM cipher wrapper
Ed25519KeyPair
Ed25519 key pair for signing
HmacAuthenticator
HMAC-SHA256 authenticator
MlDsa65KeyPair
ML-DSA-65 (Dilithium3) key pair for post-quantum signatures
MlKem768KeyPair
ML-KEM-768 (Kyber) key pair for post-quantum key exchange
ReplayCache
Thread-safe replay cache for nonce/UUID deduplication
UuidReplayCache
UUID-based replay cache (16-byte keys)
X25519KeyPair
X25519 key pair for ECDH key exchange

Enums§

AesError
HmacError
KeyError

Functions§

derive_aes_key
Derive AES key from X25519 shared secret using SHA256