rustls::crypto::hpke

Trait HpkeSealer

Source
pub trait HpkeSealer:
    Debug
    + Send
    + Sync
    + 'static {
    // Required method
    fn seal(&mut self, aad: &[u8], plaintext: &[u8]) -> Result<Vec<u8>, Error>;
}
Expand description

An HPKE sealer context.

This is a stateful object that can be used to seal messages for receipt by a receiver.

Required Methods§

Source

fn seal(&mut self, aad: &[u8], plaintext: &[u8]) -> Result<Vec<u8>, Error>

Seal the provided plaintext with additional data aad, returning ciphertext.

Implementors§