Skip to main content

pd_cipher::encryptors::chacha_poly

ChaCha20-Poly1305 stream cipher implementations.

Type Aliases

ChaCha20Poly1305Encryptor

ChaCha20-Poly1305 stream cipher with Poly1305 MAC authentication.

This encryptor uses the ChaCha20 stream cipher with Poly1305 MAC for authenticated encryption. Fast on software-only implementations and the default algorithm choice.

pub type ChaCha20Poly1305Encryptor = ...

XChaCha20Poly1305Encryptor

Extended-nonce ChaCha20-Poly1305 for applications requiring larger nonce space.

This variant uses XChaCha20 (extended ChaCha20) with a 192-bit nonce instead of the standard 96-bit nonce, reducing the risk of nonce collisions in high-volume applications.

pub type XChaCha20Poly1305Encryptor = ...