Type Alias chacha20::XChaCha20

source ·
pub type XChaCha20 = StreamCipherCoreWrapper<XChaChaCore<U10>>;
Expand description

XChaCha is a ChaCha20 variant with an extended 192-bit (24-byte) nonce.

The construction is an adaptation of the same techniques used by XChaCha as described in the paper “Extending the Salsa20 Nonce”, applied to the 96-bit nonce variant of ChaCha20, and derive a separate subkey/nonce for each extended nonce:

https://cr.yp.to/snuffle/xsalsa-20081128.pdf

No authoritative specification exists for XChaCha20, however the construction has “rough consensus and running code” in the form of several interoperable libraries and protocols (e.g. libsodium, WireGuard) and is documented in an (expired) IETF draft:

https://tools.ietf.org/html/draft-arciszewski-xchacha-03

Aliased Type§

struct XChaCha20 { /* private fields */ }