Struct crypto::voice::FrameOpener
zaun_community_protocol::crypto::voice::FrameOpener · Struct
pub struct FrameOpener { … }Opens one sender’s frames for one KID, rejecting replays.
Methods
Section titled “Methods”pub fn new(base: &SenderKey, kid: u64) -> SelfAn opener for base under kid (decryption only).
pub const fn kid(&self) -> u64The KID this opener accepts.
pub fn open(&mut self, metadata: &[u8], frame: &[u8]) -> Result<Vec<u8>, VoiceError>Opens a sealed frame. The counter is recorded only once the frame authenticates.
Errors
Section titled “Errors”VoiceError::Header, VoiceError::UnknownKid for another KID,
VoiceError::Replay or VoiceError::Open.
Trait implementations
Section titled “Trait implementations”Debug