Application messages in OpenMLS allow encrypted communication between group members. These messages are always encrypted usingDocumentation Index
Fetch the complete documentation index at: https://mintlify.com/openmls/openmls/llms.txt
Use this file to discover all available pages before exploring further.
PrivateMessage framing.
Overview
Application messages carry arbitrary application data between group members. Unlike proposals and commits, application messages do not modify group state.Message Flow
FramedContentBody::Application
The application content is wrapped in aFramedContentBody variant.
Variable-length byte array containing application data
Creating Application Messages
ContentType
Application messages use theApplication content type.
Indicates this message contains application data
Properties
Returns
false for application messages (only Proposal and Commit are handshake messages)PrivateMessage
Application messages are always encrypted asPrivateMessage for confidentiality.
Structure
Identifier of the group this message belongs to
The epoch in which this message was sent
Set to
ContentType::Application (1) for application messagesAdditional authenticated data (AAD) provided by the sender
Encrypted sender information (leaf index, generation, reuse guard)
Encrypted application payload with authentication tag
Encryption
Application messages use AEAD encryption with keys derived from the secret tree.Decryption
Sender Data Encryption
The sender’s identity is encrypted separately to provide metadata privacy.MlsSenderData
The sender’s leaf index in the ratchet tree
The generation of the secret tree key used for encryption
Random value to prevent nonce reuse
Sender Data AAD
Padding
Application messages can include padding to obscure message length.Padding block size in bytes. Actual padding will align the ciphertext to this block size.
Security Considerations
Forward Secrecy
Application messages provide forward secrecy through key ratcheting:- Each message uses a unique key derived from the secret tree
- Keys are deleted after use
- Compromise of current keys does not compromise past messages
Metadata Privacy
The sender’s identity is encrypted to prevent traffic analysis:- Sender data is encrypted separately from content
- Only group members can determine who sent a message
Ordering
Application messages can be processed out-of-order within the same epoch:- Each sender maintains their own ratchet
- Generation counters track message sequence per sender
Error Handling
Encryption Errors
Decryption Errors
Examples
Send Application Message
Receive Application Message
With Authenticated Data
Related Types
- Message Framing - MlsMessageIn/Out wrapper types
- Proposals - Group modification proposals
- Commits - Group state transitions