Module wire

Module wire 

Source
Expand description

Implementation of the transport protocol.

We use the Noise XK handshake pattern to establish an encrypted stream with a remote peer. The handshake itself is implemented in the external cyphernet and netservices crates.

Modules§

frame
Framing protocol.
message
varint
Variable-length integer implementation based on QUIC.

Structs§

Frame
Protocol frame.
StreamId
Identifies a (multiplexed) stream.
Wire
Wire protocol implementation for a set of peers.

Enums§

AddressType
Address type.
Control
Control message used internally between workers, users, and the service.
Error
FrameData
Frame payload.
Invalid
MessageType
Message type.

Constants§

DEFAULT_CONNECTION_TIMEOUT
Default time to wait until a network connection is considered inactive.
DEFAULT_DIAL_TIMEOUT
Default time to wait when dialing a connection, before the remote is considered unreachable.
MAX_INBOX_SIZE
Maximum size of a peer inbox, in bytes.
NOISE_XK
NoiseXK handshake pattern.

Traits§

Decode
Things that can be decoded from binary.
Encode
Things that can be encoded as binary.

Functions§

accept
Accept a new connection.
dial
Establish a new outgoing connection.

Type Aliases§

Size
The default type we use to represent sizes on the wire.
WireReader
Peer session type (read-only).
WireSession
Peer session type.
WireWriter
Peer session type (write-only).