Owner: @Marcin Pawlowski

Reviewers: 🟢@Youngjoon Lee 🟢@Alexander Mozeika 🟢@Álvaro Castro-Castilla

Introduction

This document defines an implementation-friendly specification of the Message Formatting, which is introduced in the Formatting section.

In this document we are reusing notation from Notation.

Overview

The message contains a header and a payload. The header informs the protocol about the version of the protocol and the payload type. The message contains a drop or a non-drop payload. The length of a payload is fixed to prevent adversaries from distinguishing types of messages based on their length.

Construction

Message

The Message is a structure that contains a public_header, private_header and a payload.

class Message:
  	public_header: PublicHeader,
	  private_header: Private_Header,
	  payload: bytes

Public Header

The public_header must be generated as the outcome of the Message Encapsulation Mechanism.

The public_header is defined as follows:

class PublicHeader:
		version: byte,
  	public_key: PublicKey,
	  proof_of_quota: ProofOfQuota,
  	signature: Signature

Where: