Skip to main content

Module storage_encryption_layer

Module storage_encryption_layer 

Source
Expand description

Storage Encryption Layer (storage_encryption_layer)

Production-quality encryption layer for block storage using pure-Rust stream cipher implementations (ChaCha20, XSalsa20, Xor256).

Features:

  • Inline ChaCha20 (20-round, quarter-round based)
  • Inline XSalsa20 (HSalsa20 key derivation + Salsa20)
  • Xor256 (256-byte repeating XOR for testing)
  • Key store with rotation support
  • Encrypted block index for decrypt-by-CID lookup
  • Bounded audit log (1000 entries)
  • FNV-1a MAC verification
  • Batch encrypt / re-encrypt operations

Structs§

EncAuditEntry
A single entry in the bounded audit log.
SelEncryptedBlockRecord
Index record for an encrypted block.
SelEncryptionConfig
Configuration for StorageEncryptionLayer.
SelEncryptionKey
A symmetric encryption key with metadata.
SelEncryptionStats
Aggregate statistics for StorageEncryptionLayer.
StorageEncryptionLayer
A pure-Rust encryption layer for block storage.

Enums§

SelCipher
Stream cipher variant to use for block encryption.
SelError
Errors produced by StorageEncryptionLayer.

Type Aliases§

BlockCid
32-byte block content identifier.
EncryptedBlockRecord
Public type alias for SelEncryptedBlockRecord.
EncryptionKey
Public type alias for SelEncryptionKey.
KeyId
16-byte key identifier.
SelStorageEncryptionLayer
Public type alias for StorageEncryptionLayer.