Crate fxfs_crypto

source ·



  • A thin wrapper around a ChaCha20 stream cipher. This will use a zero nonce. NOTE: Great care must be taken not to encrypt different plaintext with the same key and offset (even across multiple boots), so consider if this suits your purpose before using it.
  • To support key rolling and clones, a file can have more than one key. Each key has an ID that unique to the file.


  • Different keys are used for metadata and data in order to make certain operations requiring a metadata key rotation (e.g. secure erase) more efficient.



  • An interface trait with the ability to wrap and unwrap encryption keys.

Type Aliases