aboutsummaryrefslogtreecommitdiffstats
path: root/src/config/mod.rs
diff options
context:
space:
mode:
authortv <tv@krebsco.de>2026-11-08 21:49:45 +0000
committertv <tv@krebsco.de>2026-11-08 22:58:47 +0100
commita3eadeeeff9f4ae8ce91251e51d8312a6ffbc2ca (patch)
tree755f1edfd4e44202ffb70bd596419a2d63b0ad03 /src/config/mod.rs
parent46978f2b6b102750bcc8eef3b0b286b6008240f7 (diff)
roots: a joiner takes a root once its seeds named it
Review 3, R2: the root pin was set by the first HELLO_REPLY, and the first sync, a round trip later, took that root; a peer naming another afterwards was refused as another history. So the seed that answered first decided, not "none while they disagree", and a malicious seed makes itself fastest. A node joining with an empty document of the first epoch now takes no root (RootPin::Awaiting, roots left for later) until each of its seeds named one, or ROOT_WAIT (10 s) passed since the first did; then the one they name, none while they differ, as before. With --genesis-root it takes that one alone, at once. access.md, the option's help and example.toml say so; switching roots later, while the joiner holds nothing of its own, is postponed.
Diffstat (limited to 'src/config/mod.rs')
-rw-r--r--src/config/mod.rs2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/config/mod.rs b/src/config/mod.rs
index 572960b..34ed709 100644
--- a/src/config/mod.rs
+++ b/src/config/mod.rs
@@ -191,7 +191,7 @@ pub(crate) const OPTIONS: &[OptionSpec] = &[
Kind::Text,
"HASH",
None,
- "The hash of the swarm's genesis change (hex, as its genesis node logs it and GET /admin/epochs shows it): joining with an empty document, the only root this node takes. Without, the one its peers name, none while they name different ones (docs/access.md).",
+ "The hash of the swarm's genesis change (hex, as its genesis node logs it and GET /admin/epochs shows it): joining with an empty document, the only root this node takes. Without, the one its peers name once each seed named one or ten seconds passed since the first did, none while they name different ones (docs/access.md).",
),
option(
"strict-keys",