Skip to content

chacha20: reexport the Nonce type #569

@kennytm

Description

@kennytm

In v0.10.0, we see that XNonce and LegacyNonce are exported, but the standard Nonce type remains private to crate.

The Nonce type was available in 0.9.1. https://docs.rs/chacha20/0.9.1/chacha20/type.Nonce.html

#[cfg(feature = "cipher")]
pub use chacha::{ChaCha8, ChaCha12, ChaCha20, Key, KeyIvInit};
#[cfg(feature = "cipher")]
pub use cipher;
#[cfg(feature = "legacy")]
pub use legacy::{ChaCha20Legacy, LegacyNonce};
#[cfg(feature = "rng")]
pub use rand_core;
#[cfg(feature = "rng")]
pub use rng::{ChaCha8Rng, ChaCha12Rng, ChaCha20Rng, Seed, SerializedRngState};
#[cfg(feature = "xchacha")]
pub use xchacha::{XChaCha8, XChaCha12, XChaCha20, XNonce, hchacha};

The Nonce type is internally accessible from crate::chacha::Nonce.

/// Nonce type used by ChaCha variants.
pub type Nonce = Array<u8, U12>;

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions