AeadDecryptable

AeadDecryptable

Mojo trait 🡭

AeadDecryptable

Decryption of an AEAD scheme.

Verifies a tag_size-byte tag over aad and the ciphertext data, then decrypts data in place.

Implemented traits

AnyType

Methods

decrypt

fn def decrypt[tag_size: Int, aad_o: Origin[mut=aad_o.mut], o: MutOrigin](mut self, aad: Span[UInt8, aad_o], data: Span[UInt8, o], tag: Array[UInt8, tag_size])

Verify tag, then decrypt data in place.

Parameters:

  • tag_size (Int)
  • aad_o (Origin[mut=mut])
  • o (MutOrigin)

Args:

  • self (Self)
  • aad (Span[UInt8, aad_o])
  • data (Span[UInt8, o])
  • tag (Array[UInt8, tag_size])

Raises: