Expand description
Sans-io QUIC v1 transport (RFC 9000, RFC 9001, RFC 9002) for simoom, with QUIC v2
(RFC 9369) when enabled in Config::versions.
The crate never touches sockets or clocks: an Endpoint takes datagrams, the time and
the peer address, and returns datagrams to send, a deadline and per-connection events.
Packet protection and the TLS handshake go through the crypto traits.
Re-exports§
pub use config::Config;pub use config::TransportConfig;pub use connection::Connection;pub use connection::ConnectionError;pub use connection::EndpointEvent;pub use connection::Event;pub use connection::Stats;pub use connection::Transmit;pub use crypto::CryptoProvider;pub use crypto::CryptoSession;pub use crypto::Level;pub use endpoint::ConnHandle;pub use endpoint::DatagramEvent;pub use endpoint::Endpoint;pub use error::StreamError;pub use error::TransportError;pub use packet::VERSION_1;pub use packet::VERSION_2;pub use params::Cid;pub use params::TransportParams;
Modules§
- coding
- Variable-length integers (RFC 9000 §16) and a bounds-checked reader.
- config
- Endpoint and transport configuration.
- connection
- The QUIC connection state machine (RFC 9000, RFC 9001, RFC 9002), sans-io.
- crypto
- The crypto boundary between the transport and TLS (RFC 9001).
- endpoint
- An endpoint: routes datagrams to connections by connection ID, creates server connections, and answers statelessly (Version Negotiation, Retry, stateless reset). It also keeps one deadline heap for all its connections.
- error
- Transport error codes (RFC 9000 §20).
- frame
- QUIC frames (RFC 9000 §19): zero-copy parsing and encoding.
- packet
- Packet headers, packet numbers, header protection, Version Negotiation, Retry and stateless reset (RFC 9000 §17, RFC 9001 §5).
- params
- Transport parameters (RFC 9000 §18): encoding, decoding and validation.
- ranges
- A set of disjoint half-open
u64ranges, kept sorted. Used for ACK ranges, received packet numbers and stream retransmission bookkeeping. - recovery
- Loss detection, PTO and congestion control (RFC 9002), with a token-bucket pacer.
- sim
- A deterministic in-memory network for tests and benchmarks: two endpoints joined by links that can drop, duplicate, reorder and delay datagrams, with an optional bottleneck (bandwidth and queue). Time is virtual and advanced by the simulation.
- stream
- Streams (RFC 9000 §2–4): send and receive buffers, stream and connection flow control, stream limits, STOP_SENDING and RESET_STREAM.
- tls
- The production
CryptoProvider: TLS 1.3 fromsimoom_tls::quic(RFC 9001), with AES-GCM or ChaCha20-Poly1305 packet protection, the Retry integrity tag, HMAC-SHA256 for tokens and the TLS crate’s DRBG for randomness. - token
- Address-validation tokens for Retry and NEW_TOKEN (RFC 9000 §8.1), authenticated with HMAC-SHA256 under the endpoint’s token key.
- vn
- Compatible version negotiation (RFC 9368) between QUIC v1 and v2 (RFC 9369).