1 unstable release
| 0.1.0 | Jan 6, 2026 |
|---|
#14 in #handshake
Used in zks
190KB
3.5K
SLoC
zks_proto
Protocol layer for the ZKS Protocol - handshake and URL parsing.
Overview
This crate implements the ZKS Protocol message layer:
- 3-Message Handshake - Post-quantum secure key exchange
- URL Parsing -
zk://andzks://protocol handlers - Message Types - Structured protocol messages
- Error Handling - Protocol-specific errors
Handshake Flow
Initiator Responder
│ │
│ 1. HandshakeInit │
│ ────────────────────────────────► │
│ [ephemeral_pk, nonce] │
│ │
│ 2. HandshakeResponse │
│ ◄──────────────────────────────── │
│ [ephemeral_pk, ciphertext, sig] │
│ │
│ 3. HandshakeFinish │
│ ────────────────────────────────► │
│ [confirmation_hash] │
│ │
Usage
use zks_proto::url::ZksUrl;
let url = ZksUrl::parse("zks://example.com:8443/room123")?;
println!("Protocol: {}", url.protocol());
println!("Host: {}", url.host());
License
AGPL-3.0-only
Dependencies
~25–51MB
~819K SLoC