Skip to main content

net_wire/
lib.rs

1#![no_std]
2#![deny(missing_docs)]
3
4//! Borrowed, allocation-free views of network wire layouts.
5//!
6//! This crate performs no I/O or allocation. The default feature set is empty. Protocols are
7//! selected explicitly; intrinsic lower-protocol requirements are enabled transitively, while
8//! optional adapters remain orthogonal.
9
10mod error;
11#[cfg(any(
12    feature = "ipv4",
13    feature = "icmpv4",
14    all(feature = "ipv4", any(feature = "udp", feature = "tcp")),
15    all(
16        feature = "ipv6",
17        any(feature = "icmpv6", feature = "udp", feature = "tcp")
18    )
19))]
20mod internet_checksum;
21#[cfg(any(feature = "http2", feature = "qpack"))]
22mod rfc7541_huffman;
23
24#[cfg(feature = "arp")]
25/// ARP packet views, semantic fields, and caller-buffer construction.
26pub mod arp;
27#[cfg(feature = "ethernet")]
28/// Ethernet II frame views, semantic fields, and caller-buffer construction.
29pub mod ethernet;
30#[cfg(feature = "http1")]
31/// Standalone HTTP/1 head and chunked-body views and caller-buffer construction.
32pub mod http1;
33#[cfg(feature = "http2")]
34/// Standalone raw HTTP/2 preface and frame views and caller-buffer construction.
35pub mod http2;
36#[cfg(feature = "http3")]
37/// Standalone raw HTTP/3 frame views and caller-buffer construction.
38pub mod http3;
39#[cfg(feature = "icmpv4")]
40/// ICMPv4 message views and caller-buffer construction.
41pub mod icmpv4;
42#[cfg(feature = "icmpv6")]
43/// ICMPv6 message views and caller-buffer construction.
44pub mod icmpv6;
45#[cfg(feature = "ipv4")]
46/// IPv4 packet views, semantic fields, and caller-buffer construction.
47pub mod ipv4;
48#[cfg(feature = "ipv6")]
49/// IPv6 packet views, semantic fields, and caller-buffer construction.
50pub mod ipv6;
51#[cfg(feature = "kcp")]
52/// KCP wire segment views and stateless scalar helpers.
53pub mod kcp;
54#[cfg(feature = "qpack")]
55/// Standalone QPACK prefixed integers, Huffman payloads, and string-literal views.
56pub mod qpack;
57#[cfg(feature = "quic")]
58/// Standalone QUIC wire primitives and borrowed packet-header views.
59pub mod quic;
60#[cfg(feature = "tcp")]
61/// TCP segment views and caller-buffer construction.
62pub mod tcp;
63#[cfg(feature = "tls")]
64/// TLS record and handshake views and caller-buffer construction.
65pub mod tls;
66#[cfg(feature = "udp")]
67/// UDP datagram views and caller-buffer construction.
68pub mod udp;
69
70pub use error::ParseError;