GeezerVison is showing github.com — id: native bridge dialer in id-sync — the Rust peer role over the bridge wire (#3818) by dezren39 · Pull Request #12993 · developing-today/code
Conversation
dezren39
commented
Nov 23, 2026
•
edited by blacksmith-sh
Bot
Loading
Uh oh!
There was an error while loading. Please reload this page.
Part of #3818 (does not close it — the one-shot HTTPS legs as native calls and a live native-against-hosted session test remain, named in the design record). Design source #2046; tracker #2852; PoC #2276.
What this is
The native half of the signed-object bridge v1. PR #12911 landed the hosted endpoint, protocol core and store; its design record named the remaining leg — the Rust dialer inside id-sync, the /id-range-sync/1 peer role over the bridge wire. crates/id-sync/src/bridge.rs is that dialer:
- Wire codec — one-byte tags, the batch encoding with the hosted receipt bounds enforced in the hosted codec's order, the frame cap on receipt.
- ID-key proof — the bridge-auth transcript (
id.bridge-auth.v1 / binding / nonce / leg / BLAKE3 body hash) signed with the binding record's key; the empty-body hash is the fixtures' pinned af1349b9… value.
BridgeStore — the per-step store seam (heads, sync entries, event bytes, batch ingest, chain frontier), implemented for the native EventStore over the existing RangeStore/ingest surface.
BridgeDialer — the session, mirroring the hosted reference client step for step: CHALLENGE/AUTH, HELLO or RESUME, the proof-carrying range exchange over the native range core (never a height comparison), bounded WANT/BATCH/WANT_END transfer with per-batch outcome summaries, DONE/TOKEN — plus withholding detection producing the investigation's evidence record, and sync_with_retry with the resume-rejected fallback to HELLO.
- Transport — a trait over whole messages; the production implementation is tokio-tungstenite's
WebSocketStream (new dependency edge for id-sync, already a workspace dependency), with a connect helper for /v1/bridge/ws.
Verification
cargo test -p id-sync bridge:: in nix develop (laptop worktree off origin/main): 6 passed / 0 failed — batch codec round-trip + bound refusals; transcript/body-hash pins; a full session against a mirrored server session over an in-memory transport pair converging both directions (second session resuming on the token; the convergence test additionally run 5× standalone, 5/5); withholding evidence when the server announces a head it never delivers; auth refusal for a wrong key; rejected-resume fallback.
One assertion was corrected during verification: the want order is the range exchange's learning order, not chain order, so an event can land as Waiting and be released by its predecessor — the batch tally varies, the convergence does not. The test now asserts the protocol's actual guarantee (all learned events received, none refused, store converged, chain frontier at 3).
cargo fmt --check clean for the new file; the design record's dialer bullet is updated in this PR.

Open in [code]smith · Need help on this PR? Tag @codesmith-bot with what you need.
Sorry, something went wrong.
Uh oh!
There was an error while loading. Please reload this page.
chatgpt-codex-connector[bot] reacted with thumbs up emoji
The hosted signed-object bridge v1 landed its endpoint, protocol
core and store in PR #12911; the design record named the remaining
leg: the Rust dialer inside id-sync, the /id-range-sync/1 peer role
over the bridge wire. This is that dialer.
crates/id-sync/src/bridge.rs:
- The wire codec: one-byte tags, the batch encoding with the
hosted receipt bounds enforced in the hosted codec's order, and
the frame cap on receipt.
- The ID-key proof: the bridge-auth transcript
(id.bridge-auth.v1 / binding / nonce / leg / BLAKE3 body hash),
signed with the binding record's key; the empty-body hash is the
fixtures' pinned af1349b9... value.
- BridgeStore: the per-step store seam (heads, sync entries,
event bytes, batch ingest, chain frontier), implemented for the
native EventStore over the existing RangeStore/ingest surface.
- BridgeDialer: the session, mirroring the hosted reference client
step for step — CHALLENGE/AUTH, HELLO or RESUME, the
proof-carrying range exchange over the native range core (never
a height comparison), bounded WANT/BATCH/WANT_END transfer with
per-batch outcome summaries, DONE/TOKEN — plus withholding
detection producing the investigation's evidence record, and
sync_with_retry with the resume-rejected fallback to HELLO.
- The transport seam is a trait over whole messages; the
production implementation is tokio-tungstenite's WebSocketStream
(new workspace dependency edge for id-sync), with a connect
helper for the /v1/bridge/ws endpoint.
Tests (cargo test -p id-sync bridge:: — 6 passed): batch codec
round-trip and bound refusals; transcript and body-hash pins; a
full session against a mirrored server session over an in-memory
transport pair converging both directions (6 events each side,
second session resuming on the token); withholding evidence when
the server announces a head it never delivers; auth refusal for a
wrong key; and the rejected-resume fallback. One assertion was
corrected during verification: the want order is the range
exchange's learning order, not chain order, so an event can land
as Waiting and be released by its predecessor — the tally varies,
the convergence does not.
The design record's dialer bullet is updated to match, naming the
two remainders: the one-shot HTTPS legs (challenge/heads/push/
pull) as native calls, and a live native-against-hosted session
test. Part of #3818 (does not close it). Design source #2046;
tracker #2852; PoC #2276.
Warning
Review limit reached
You've used all free OSS reviews for now. Wait for the free limit to reset to keep reviewing this public repository.
Next included review available in 8 minutes.
Check out review usage here.
View limit details
-
Limit details: You’ve used the included review currently available.
Learn how review limits work.
Review configuration:
Run configuration
-
- Source mode: Auto
- Repository: Unavailable
- Branch: Unavailable
- File: No configuration file from this repository applied
- Commit: Unavailable
- Layers: defaults
- Review profile: CHILL
- Plan: Advanced
- Run ID:
37d4603d-c5bc-423a-ae76-1b8201f85f20
Commits
-
Reviewing files that changed from the base of the PR and between 6e3f9c3 and 8ef0c2e.
Files ignored due to path filters: 1
-
pkgs/id/Cargo.lock is excluded by !**/*.lock
Files selected for processing: 4
-
doc/2026-11-23T05-00-00Z_design_bridge_v1_implementation/2026-11-23T05-00-00Z_design_bridge_v1_implementation.md
pkgs/id/crates/id-sync/Cargo.toml
pkgs/id/crates/id-sync/src/bridge.rs
pkgs/id/crates/id-sync/src/lib.rs
- Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.
Share
-
|
Sorry, something went wrong.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Codex Review Summary: ✅ Completed
This comment shows the latest Codex review activity on this pull request.
| Review |
Status |
Commit |
Review trigger |
| 📝 Code Review |
✅ Completed 2026-11-23T06:38:03.441277Z |
8ef0c2e |
PR opened |
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review" or "@codex security review".
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.
|
Sorry, something went wrong.
Uh oh!
There was an error while loading. Please reload this page.
This was referenced Nov 23, 2026
Uh oh!
There was an error while loading. Please reload this page.
Assignees
No one assigned
Milestone
No milestone
Development
Successfully merging this pull request may close these issues.
Uh oh!
There was an error while loading. Please reload this page.
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.
|