Skip to main content

Module encryption

Module encryption 

Source

Enums§

DecryptOutcome
Outcome of try_decrypt_message_typed — distinguishes a body that genuinely AEAD-decrypted from one that was merely passed through (plaintext or a fail-open decrypt failure).

Functions§

decrypt_body
BRC-78 decrypt an encrypted message body from a sender.
encrypt_body
BRC-78 encrypt a message body for a recipient.
generate_message_id
Generate a deterministic HMAC-based message ID for idempotency.
try_decrypt_message
Try to decrypt a message body, with graceful fallback for plaintext.
try_decrypt_message_typed
Typed sibling of try_decrypt_message that additionally surfaces whether the body genuinely AEAD-decrypted.