Trait BoundKey

pub trait BoundKey<N>: Debug
where N: NonceSequence,
{ // Required methods fn new(key: UnboundKey, nonce_sequence: N) -> Self; fn algorithm(&self) -> &'static Algorithm; }
Expand description

An AEAD key bound to a nonce sequence.

Required Methods§

fn new(key: UnboundKey, nonce_sequence: N) -> Self

Constructs a new key from the given UnboundKey and NonceSequence.

fn algorithm(&self) -> &'static Algorithm

The key’s AEAD algorithm.

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.

Implementors§

§

impl<N> BoundKey<N> for OpeningKey<N>
where N: NonceSequence,

§

impl<N> BoundKey<N> for SealingKey<N>
where N: NonceSequence,