Repository navigation
PRIV-601: anonymous transaction lane only by default from v0.9.0, and a first-spy test in process - #180
Merged
Conversation
…0.9.0, and a first-spy test in process A node reads its own version for the default: a v0.8.x node still subscribes and relays on the legacy signed topic, a node of v0.9.0 or later gossips transactions on the anonymous lane only. --legacy-tx-relay (new) or --legacy-tx-publish keeps the topic on such a release; --anonymous-tx-only leaves it on any release. Every node since v0.8.3 speaks the anonymous lane, so the two defaults interoperate and the release rolls host by host. tests/dandelion.rs gains the first-spy measurement in process: an observer connected to all five nodes guesses each transaction's origin as the peer that first forwarded it. Without Dandelion it must name the submitter for at least 8 of 10; with it, over a fleet mixing anonymous-only and both-lane nodes, for at most 10 of 20; no copy may reach it on the signed topic. docs/deploy.md says what the in-process test shows and what it does not, and what the fleet run has to record. Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01YGaYNQ4cvFtg2UmokVgrAN
Other tests start a node on the default lanes with it. Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01YGaYNQ4cvFtg2UmokVgrAN
Codecov Report✅ All modified and coverable lines are covered by tests. 📢 Thoughts on this report? Let us know! |
dendisuhubdy
added a commit
that referenced
this pull request
Nov 18, 2026
… Unreleased (#192) Each entry is the PR's own "Changelog line" section, which the PRs kept out of CHANGELOG.md so they would not conflict with each other: #173, #174, #176–#180, #183, #185–#188 (#175 is test-only and has none). Claude-Session: https://claude.ai/code/session_01YGaYNQ4cvFtg2UmokVgrAN Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
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.
Tracks randprotocol/monorepo#27
Kind: network (gossip topics), no consensus change, no flag day. Nothing changes on a v0.8.x build; the default flips with the version bump to v0.9.0, and a v0.9.0 node interoperates with every node since v0.8.3.
What main already does
--legacy-tx-publish, v0.8.5).--anonymous-tx-only, which no unit sets.What this adds
network::anonymous_tx_only(flag, keep_legacy, version): before v0.9.0 the legacy topic is kept unless--anonymous-tx-only; from v0.9.0 it is left unless--legacy-tx-relay(new flag) or--legacy-tx-publish. The node reads its own version, as RPC-201: refuse rand_getScanLeaves by default from v0.9.0, by the node's own version #179 does forrand_getScanLeaves, so no unit needs a flag and nothing needs editing at the bump. An unreadable version takes the private default.tests/dandelion.rs::a_first_spy_names_the_submitter_without_dandelion_and_rarely_with_it: five real nodes on loopback plus an observer connected to all of them that records the first forwarder of each transaction and the lane of each copy. Control (Dandelion off): the observer must name the submitter for at least 8 of 10. Dandelion on at the defaults, nodes 1 and 3 anonymous-only (the v0.9.0 default) and the rest on both lanes (v0.8.x): at most 10 of 20, every mempool gets every transaction, and no copy reaches the observer on the signed topic in either run.docs/deploy.md,docs/cli.md,docs/architecture.md: the v0.9.0 step, the new flag, what the in-process test shows and does not, and what the fleet run must record.Rolling upgrade
A v0.9.0 node drops only the legacy
rand/<chain>/txsubscription. v0.8.3–v0.8.6 peers publish and relay every transaction ontx/2as well, so nothing is lost in either direction (the mixed-lane fleet in the new test). A node from before v0.8.3 would stop hearing v0.9.0 nodes' relays over gossip (it still gets transactions in blocks);--legacy-tx-relayis for a chain that has one.Tests
Local (macOS, debug):
The two new unit tests (
network::tests::the_legacy_transaction_topic_is_left_by_default_from_v0_9_0, the extendedthe_legacy_signed_copy_is_opt_in) were type-checked locally (cargo check -p randprotocol-node --tests) and run in CI's library suites.What remains
docs/deploy.mdnow lists what to record. Until then origin hiding on chain 21 stays design intent.--anonymous-tx-onlystays a per-host choice; nothing here sets it on a unit.Changelog line
--anonymous-tx-only, a v0.9.0 node leaves it unless the new--legacy-tx-relay(or--legacy-tx-publish). Interoperates with every node since v0.8.3.tests/dandelion.rsnow runs a first-spy measurement in process; the fleet run is still to be recorded, so origin hiding on chain 21 remains design intent.🤖 Generated with Claude Code
https://claude.ai/code/session_01YGaYNQ4cvFtg2UmokVgrAN