4 releases (breaking)
Uses new Rust 2024
| 0.4.0 | Feb 5, 2026 |
|---|---|
| 0.3.0 | Feb 4, 2026 |
| 0.2.0 | Jan 18, 2026 |
| 0.1.0 | Jan 17, 2026 |
#3 in #ping-pong
Used in 5 crates
19KB
361 lines
apfsds-protocol
Wire protocol definitions and frame serialization for APFSDS.
Features
- Zero-copy serialization using
rkyv - ProxyFrame: Core data transmission unit with connection ID, flags, and payload
- ControlMessage: Enum for control frames (DoH, Ping/Pong, KeyRotation, Emergency)
- Authentication types:
AuthRequest,AuthResponse
Usage
use apfsds_protocol::{ProxyFrame, FrameFlags, ControlMessage};
// Create a data frame
let frame = ProxyFrame {
conn_id: 12345,
flags: FrameFlags::DATA,
payload: data.into(),
};
// Control messages
let msg = ControlMessage::Ping;
Frame Format
┌─────────────┬───────┬─────────────────────────────┐
│ conn_id (8B)│ flags │ payload (variable) │
└─────────────┴───────┴─────────────────────────────┘
License
MIT
Dependencies
~2MB
~47K SLoC