Repository navigation
feat(protocol): SessionManager — stream-session lifecycle (stream slice 3b) - #1263
Merged
Merged
Conversation
The stateful manager over the slice-1/2 crypto core: drives the Ed25519-authenticated X25519 handshake, holds a live StreamSession per peer, seals/opens frames. NO I/O — pure state machine (begin_handshake/on_init/on_resp produce+consume HandshakeInit/Resp; seal_for/open_from over the session). The caller (a future SessionTransport<T>) carries the bytes; keeping the lifecycle I/O-free makes it exhaustively testable apart from transport plumbing. ADDITIVE: nothing wires this into the live transport yet, so the SignedTransport/ LanTcp control path is byte-for-byte unchanged — zero risk to the transport reliability BigMama is hardening in parallel (announced on airc; lanes deconflicted — she's on route-health, this is session-crypto). 4 tests: full handshake→seal/open both ways, NoSession before handshake, on_resp without a pending handshake rejected, unenrolled initiator rejected (trust gate flows through the manager). 87 airc-protocol tests green, clippy clean. Next (slice 3c): SessionTransport<T> in airc-transport — auto-orchestrate the handshake over the wire + dispatch on crypto_mode, for the UDP/WebRTC adapters. Co-Authored-By: Claude Opus 4.8 <[email protected]>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What
The stateful SessionManager over the slice-1/2 crypto core (#1261): drives the Ed25519-authenticated X25519 handshake, holds a live
StreamSessionper peer, seals/opens frames. No I/O — pure state machine (begin_handshake/on_init/on_respproduce+consumeHandshakeInit/Resp;seal_for/open_fromover the session). The caller (a futureSessionTransport<T>) carries the bytes; keeping the lifecycle I/O-free makes it exhaustively testable apart from transport plumbing.Additive — zero transport-reliability risk
Nothing wires this into the live transport yet, so
SignedTransport/LanTcp control path is byte-for-byte unchanged. Announced on airc; lanes deconflicted with BigMama (she's on route-health/connection reliability; this is session-crypto).Tests (4) + 87 airc-protocol green, clippy clean
full handshake→seal/open both ways · NoSession before handshake · on_resp without a pending handshake rejected · unenrolled initiator rejected (trust gate flows through the manager).
Next — slice 3c (the wire integration, coordinated)
SessionTransport<T>in airc-transport: auto-orchestrate the handshake over the wire + dispatch oncrypto_mode, for the UDP/WebRTC adapters. That's the live-path change — to land once BigMama's transport-reliability work settles + she's current on branches.🤖 Generated with Claude Code