--- name: protocol-development description: Design and implement secure networking software in Rust or Go with Tokio, Quinn, Rustls, quic-go, TUN devices, interoperable transports, and robust protocol tests. --- # Protocol development Use the [shared knowledge workflow](../knowledge-workflow.md) to gather evidence and decide whether web fallback is needed. 1. Clarify interoperability requirements, platforms, trust boundaries, resource limits, and exact Rust or Go toolchain and dependency versions. 2. Use NetExpert `search_docs` for requirements and version-specific API support. Use `get_document` if the excerpt lacks the requirement or relevant conditions. Use `search_source` when exposed to verify implementation, feature gates, and platform differences. 3. Design explicit state and wire formats, bounded parsing, cancellation, deadlines, backpressure, and safe failure states. Use reviewed libraries for TLS and cryptography. Plan lifecycle and privilege requirements for TUN adapters separately from transport logic. 4. Validate example APIs with a minimal build against locked dependencies. Use local fixtures, interoperable peers where authorized, and deterministic tests for malformed input, cancellation, resource bounds, and adverse network conditions. 5. Cite original specs and versioned sources, marking design assumptions and untested platforms.