Encrypts a media file for sharing in a Marmot group message (MIP-04 v2).
Uses ChaCha20-Poly1305 AEAD with a randomly generated nonce. The
associated data (AAD) binds the scheme version, file hash, MIME type, and
filename to prevent metadata tampering.
Encrypts a media file for sharing in a Marmot group message (MIP-04 v2).
Uses ChaCha20-Poly1305 AEAD with a randomly generated nonce. The associated data (AAD) binds the scheme version, file hash, MIME type, and filename to prevent metadata tampering.
Typical usage: