Skip to main content

WIRE_VERSION

Constant WIRE_VERSION 

Source
pub const WIRE_VERSION: u8 = 2;
Expand description

Wire-format version. Bumped only on incompatible envelope changes.

v=2 (CR-6): for MessageKind::Application, content_hash is computed over the plaintext instead of the ciphertext payload. Handshake kinds (Commit / Welcome / Proposal / KeyPackage) keep the v=1 semantics — content_hash = SHA-256(kind || payload). See MessageEnvelope::new_application for the production constructor.

Receivers run a 90-day dual-accept window per Q-ARCH-02: any envelope with v ∈ {1, 2} is structurally accepted; the validate layer routes hash-check semantics by version. Clients SHOULD refuse v=1 once the window expires.