Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 11 additions & 1 deletion proto/mls/api/v1/mls.proto
Original file line number Diff line number Diff line change
Expand Up @@ -218,14 +218,24 @@ message GroupMessage {
bytes data = 4;
bytes sender_hmac = 5;
bool should_push = 6;
bool is_commit = 7;
bool is_commit = 7 [deprecated = true];
MessageType message_type = 8;
}

oneof version {
V1 v1 = 1;
}
}

// Enum to specify the type of a message.
// Primarily used for ordering while retaining some metadata.
enum MessageType {
MESSAGE_TYPE_UNSPECIFIED = 0;
MESSAGE_TYPE_APPLICATION = 1;
MESSAGE_TYPE_COMMIT = 2;
MESSAGE_TYPE_FORK_ADMIN_CHANGE = 3;
}

// Input type for a group message
message GroupMessageInput {
// Version 1 of the GroupMessageInput payload format
Expand Down
21 changes: 19 additions & 2 deletions proto/mls/message_contents/commit_log.proto
Original file line number Diff line number Diff line change
Expand Up @@ -22,17 +22,34 @@ message PlaintextCommitLogEntry {
// The sequence ID of the commit payload being validated.
uint64 commit_sequence_id = 2;
// The encryption state before the commit was applied.
bytes last_epoch_authenticator = 3;
bytes last_epoch_authenticator = 3 [deprecated = true];
// Indicates whether the commit was successful, or why it failed.
CommitResult commit_result = 4;
// The epoch number after the commit was applied, if successful.
uint64 applied_epoch_number = 5;
// The encryption state after the commit was applied, if successful.
bytes applied_epoch_authenticator = 6;

// The hmac of the installation_id that published this commit log entry.
// Value: hmac-sha256(salt, installation_id)
bytes installation_hmac = 7;
}

message CommitLogEntry {
uint64 sequence_id = 1;
bytes serialized_commit_log_entry = 2;
xmtp.identity.associations.RecoverableEd25519Signature signature = 3;
xmtp.identity.associations.RecoverableEd25519Signature deprecated_signature = 3 [deprecated = true];

// Installation cred signature on field 2 + group salt
bytes signature = 4;
}

message ForkAdminChange {
// Used to protect against replays, and against replays for new members.
int64 sequence_id = 1;
// value: hmac-sha256(group salt, installation_id)
bytes fork_admin_hmac = 2;
// Installation cred signature on fields 1 + 2 + 4 + group salt
bytes signature = 3;
bytes group_id = 4;
}
4 changes: 3 additions & 1 deletion proto/mls_validation/v1/service.proto
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ package xmtp.mls_validation.v1;
import "identity/api/v1/identity.proto";
import "identity/associations/association.proto";
import "identity/credential.proto";
import "mls/api/v1/mls.proto";

option go_package = "github.com/xmtp/proto/v3/go/mls_validation/v1";

Expand Down Expand Up @@ -98,7 +99,8 @@ message ValidateGroupMessagesResponse {
bool is_ok = 1;
string error_message = 2;
string group_id = 3;
bool is_commit = 4;
bool is_commit = 4 [deprecated = true];
xmtp.mls.api.v1.MessageType message_type = 5;
}

repeated ValidationResponse responses = 1;
Expand Down
Loading