openmls 0.4.1

This is a WIP Rust implementation of the Messaging Layer Security (MLS) protocol based on draft 12+.
Documentation
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
//! This module contains code to serialize `MlsMessage`/`MlsMessageIn` as used
//! by the MlsGroup API, which the Clients are built on. These
//! serialization/deserialization functions attach an additional byte that
//! indicates if a message is a plaintext or a ciphertext

use tls_codec::{TlsDeserialize, TlsSerialize, TlsSize};

/// Enum defining encodings for the different message types/
#[derive(Debug, Clone, Copy, TlsSerialize, TlsDeserialize, TlsSize)]
#[repr(u8)]
pub enum MessageType {
    /// An MlsCiphertext message.
    MlsCiphertext = 0,

    /// An MlsPlaintext message.
    MlsPlaintext = 1,
}