Documentation 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.
Frequently Asked Questions
Answers to common questions about the MLS protocol and OpenMLS library.General MLS Questions
What is MLS (Messaging Layer Security)?
What is MLS (Messaging Layer Security)?
- Confidentiality: Messages are only readable by group members
- Authentication: Members can verify message senders
- Forward Secrecy: Past messages remain secure if keys are compromised
- Post-Compromise Security: Security is restored after key material is compromised
- Efficient Group Operations: Optimized for adding/removing members
How does MLS differ from Signal Protocol or OMEMO?
How does MLS differ from Signal Protocol or OMEMO?
- They use pairwise sessions between participants
- Group operations scale poorly with group size
- Uses a shared tree structure (ratchet tree) for efficient key derivation
- Add/remove operations are O(log n) instead of O(n)
- Better suited for large groups and frequent membership changes
- Standardized by IETF with multiple implementations
What is a ratchet tree in MLS?
What is a ratchet tree in MLS?
- Leaves represent group members
- Nodes contain key material used to derive encryption keys
- Root provides the group secret shared by all members
- Updates affect only O(log n) nodes instead of all members
- Provides forward secrecy and post-compromise security
- Allows efficient key derivation for all group members
What are epochs in MLS?
What are epochs in MLS?
- Each commit advances the group to a new epoch
- Epoch numbers increment sequentially (0, 1, 2, …)
- Messages from old epochs cannot decrypt messages from new epochs
- Each epoch has its own encryption secrets
- Clear security boundaries
- Forward secrecy (old epoch keys are deleted)
- Ordering guarantees for group operations
OpenMLS Library Questions
What platforms and languages does OpenMLS support?
What platforms and languages does OpenMLS support?
- Native Rust applications
- C/C++ via FFI bindings
- WebAssembly for browser and Node.js (with
jsfeature) - Mobile platforms (iOS, Android) through FFI
- Official Rust API
- Community-maintained bindings for other languages
js feature flag for platform compatibility.Which ciphersuites are supported?
Which ciphersuites are supported?
MLS_128_DHKEMX25519_AES128GCM_SHA256_Ed25519MLS_128_DHKEMX25519_CHACHA20POLY1305_SHA256_Ed25519
MLS_256_DHKEMX448_AES256GCM_SHA512_Ed448MLS_256_DHKEMX448_CHACHA20POLY1305_SHA512_Ed448MLS_128_DHKEMP256_AES128GCM_SHA256_P256MLS_256_DHKEMP384_AES256GCM_SHA384_P384MLS_256_DHKEMP521_AES256GCM_SHA512_P521
- XWing hybrid post-quantum KEM (with libcrux provider)
What is a crypto provider in OpenMLS?
What is a crypto provider in OpenMLS?
openmls_rust_crypto: Pure Rust implementation using RustCryptoopenmls_libcrux_crypto: Formally verified cryptography via Libcrux
OpenMlsCrypto: Cryptographic operations (AEAD, hashing, signatures)OpenMlsRand: Random number generationStorageProvider: Persistent storage for groups and keys
- Platform-specific optimizations
- HSM integration for key operations
- Custom storage backends
How do I store and retrieve groups?
How do I store and retrieve groups?
StorageProvider trait for persistence:MemoryStorage: In-memory (not persistent)SqliteStorage: SQLite-backed persistence
StorageProvider trait for your database.What are KeyPackages and how long are they valid?
What are KeyPackages and how long are they valid?
- Set expiration based on your rotation policy (e.g., 90 days)
- Upload new KeyPackages before old ones expire
- Use
LastResortExtensionfor KeyPackages that can be reused
- Generate multiple KeyPackages (one per expected group join)
- Delete KeyPackage after use unless it has
LastResortExtension - Rotate regularly to maintain security
Can I use the same KeyPackage to join multiple groups?
Can I use the same KeyPackage to join multiple groups?
LastResortExtension:- The KeyPackage can be reused for multiple groups
- The encryption keypair is not deleted after use
- Useful for always-available KeyPackages
Group Operations
What's the difference between proposals and commits?
What's the difference between proposals and commits?
- Add a member
- Remove a member
- Update own key material
- Modify group context extensions
- Can include multiple proposals
- Only one commit per epoch succeeds
- Generates new encryption keys
- Produces Welcome messages for new members
How do I handle commit conflicts?
How do I handle commit conflicts?
- Implement retry logic for commit conflicts
- Use a coordination service for large groups
- Consider proposal-only mode for non-admin members
What are external commits and when should I use them?
What are external commits and when should I use them?
- Rejoining after being removed
- Adding yourself to a public group
- Recovery from lost state
- Group must allow external commits (via
ExternalSendersExtension) - You need access to current
GroupInfo
How do I handle members who go offline?
How do I handle members who go offline?
- Messages are encrypted for current group state
- Offline members receive messages when they come online
- Use your delivery service to queue messages
- Commits advance the epoch immediately
- Offline members must process all missed commits in order
- Old epoch messages are buffered
Security and Best Practices
How does forward secrecy work in MLS?
How does forward secrecy work in MLS?
- Epoch-based key rotation: Each commit generates new encryption keys
- Key deletion: Old epoch keys are deleted after use
- Ratchet tree updates: Members update their tree position over time
- After sending N messages
- On a time schedule (e.g., daily)
- When security posture changes
What is post-compromise security?
What is post-compromise security?
- After your key is compromised, perform an update
- The update introduces fresh randomness unknown to the attacker
- After all other members commit, your security is restored
- Immediate: Attacker can’t send messages as you
- After your update: Forward secrecy for future messages
- After all members update: Full PCS restored
Should I validate all group members' credentials?
Should I validate all group members' credentials?
- X.509 certificates: Verify against trusted CAs
- Basic credentials: Check against allowlist
- Custom credentials: Application-specific validation
How should I handle key material and secrets?
How should I handle key material and secrets?
- Use secure storage:
- Delete old key material:
- Protect signing keys:
- Store in HSM or secure enclave if available
- Never log or transmit private keys
- Use separate keys for different purposes
- Handle exported secrets carefully:
Troubleshooting
Why am I getting 'UnableToDecrypt' errors?
Why am I getting 'UnableToDecrypt' errors?
- Out-of-order message processing:
- Missed commits:
- You must process ALL commits in order
- Request missing messages from server
- Wrong group state:
- Ensure you’re using the correct group instance
- Check group ID matches
- Storage issues:
- Verify secret tree is persisted correctly
- Check encryption keypairs are available
How do I debug MLS protocol errors?
How do I debug MLS protocol errors?
Extensions and Advanced Features
What MLS extensions does OpenMLS support?
What MLS extensions does OpenMLS support?
ApplicationId: Application-specific identifiersRatchetTree: Include full tree in WelcomeRequiredCapabilities: Enforce capability requirementsExternalPub: Public key for external sendersExternalSenders: Allow specific external sendersLastResort: Reusable KeyPackages
extensions-draft-08 feature):SafeExporter: Secure context binding for exportersAppEphemeral: Ephemeral application dataSelfRemove: Members can remove themselves
- Automatic handling of unknown extensions
with_grease()to add random GREASE values
How do I use custom proposals?
How do I use custom proposals?
Still Have Questions?
If your question isn’t answered here:- Check the API documentation
- Review the troubleshooting guide
- Search GitHub issues
- Ask on GitHub Discussions
- Read the MLS RFC 9420