Expand description
Varta Lifeline Protocol — 32-byte fixed-layout health frame.
This crate is the protocol root for Varta v0.1.0. It defines the on-wire
Frame representation that agents emit and observers decode, the
Status enum that classifies an agent’s last reported health, and the
DecodeError returned when validation fails. Every helper operates on
fixed-size byte arrays so the steady-state path on either side of the
socket is heap-clean.
The crate compiles as #![no_std] by default and pulls in zero allocator
usage; the optional std feature enables Key::from_file and related
std::path::Path-typed conveniences.
See book/src/architecture/vlp-frame.md for the byte map and design notes.
Re-exports§
pub use util::ct_eq;pub use util::decode_hex_32;pub use util::HexDecodeError;
Modules§
- crc32c
- CRC-32C (Castagnoli) — wire-frame integrity check.
- util
- Allocation-free utilities shared across protocol layers.
Structs§
- Frame
- On-wire health frame — exactly 32 bytes, 8-byte aligned, little-endian
integer fields. The struct is
repr(C)so its layout is ABI-stable across compilations and trivially verifiable by inspection.
Enums§
- Decode
Error - Error returned by
Frame::decodeandStatus::try_from_u8. - Status
- Health status reported by an agent in a single VLP frame.
Constants§
- MAGIC
- Magic prefix on every VLP frame. ASCII
"VA", intentionally readable in hex dumps so a stray byte stream is easy to identify. - NONCE_
TERMINAL - Sentinel nonce value reserved for terminal panic frames.
- VERSION
- Current Varta Lifeline Protocol version. v0.2 introduces the CRC-32C
integrity trailer at bytes 28..32 and shrinks
payloadfromu64tou32to fit it. v0.1 frames decode asDecodeError::BadVersion.