Crate mpc_protocol
source ·Expand description
Relay service protocol types, encoding and helper functions.
Size Limitations
The maximum size of a noise protocol message is 65535 and we further limit the size of buffers for encoding to 32KB.
Re-exports
Structs
- Key pair used by the noise protocol.
- Parameters used during key generation.
- Sealed envelope is an encrypted message.
- Session is a namespace for a group of participants to communicate for a series of rounds.
- Manages a collection of sessions.
- Request to create a new session.
- Response from creating new session.
Enums
- Encoding for message payloads.
- Errors generated by the relay protocol.
- Handshake messages.
- Opaque messaages are encrypted.
- Enumeration of protocol states.
- Request message sent to the server or another peer.
- Response message sent by the server or a peer.
- Message sent between the server and a client.
- Transparent messages are not encrypted.
Constants
- Noise protocol pattern.
- Tag for PEM encoding of noise pattern.
- Tag for PEM encoding of private key.
- Tag for PEM encoding of public key.
- Tag length for the noise protocol.
- Version for binary encoding.
Functions
- Decode from a binary buffer.
- Decode from a PEM-encoded string into a keypair.
- Encode to a binary buffer.
- Encode a keypair into a PEM-encoded string.
- Generate a keypair for the noise protocol using the standard pattern.
Type Definitions
- Party number.
- Result type for the protocol library.
- Round number.
- Identifier for sessions.