aboutsummaryrefslogtreecommitdiffstats
path: root/src/config
Commit message (Collapse)AuthorAgeFilesLines
* node: `--store-root` holding a fork's root and the events it keepstv19 hours1-1/+1
| | | | | | | The file `--store-root` names holds the store's root on its first line, and, for a fork, the events the root keeps, each on a line of its own (JCS writes no line break). The node checks that the federation takes them as a store's root with what it keeps, and starts from the changes founding the swarm, built from them.
* federation: a rule voting `false` on a checkpoint proposed beside one a node ↵tv19 hours1-0/+12
| | | | | | | | | | backs `--store-nay-beside`, for a node voting by itself: where its party backs a proposal on the current version that can still pass, by its record or by what it votes now, it votes `false` on every other proposal there that only moves to a checkpoint and can still pass, once. So, of two checkpoints proposed at once, the one it doesn't back dies, and its backers are free (`docs/federation.md`, Votes a node casts by itself).
* node: votes it casts by itself, for its partytv21 hours1-0/+147
| | | | | | | | | | | | | | | | | | | | | | A node may vote and propose for its party by itself, by its operator's rules (`docs/federation.md`, Votes a node casts by itself; `federation::vote`): * `--store-vote-key`: the party's key it signs with, an OpenSSH private key file, one the party's version names, kept on the node; * `--store-vote-record`: its party's one record of its votes, which it votes by, written before each vote is sent, begun where there is none on the version current then; * `--store-follow`, `--store-follow-any`: the parties it follows, by default only on a version that only moves to a checkpoint; * `--store-propose-events`, `--store-propose-every`: when it proposes a checkpoint, once it holds so many events beyond its checkpoint, or so long after its store moved there; * `--store-held-for` (10 minutes): how long it holds an event before it holds it for a while, for the heads it proposes and the voters' rule. Its store keeps when, by the node's own clock, it took each event, and when it moved to its checkpoint. Whenever the worker reads the store, the node decides what to sign (`Holding::act`), records it, writes the record, offers it to its store, and puts it into the document (`held::write`). A vote by hand through the node, by the record and the voters' rule, is `Holding::vote_by_hand`.
* topology: neighbours among the members of a node's own party, and of parties ↵tv23 hours1-0/+40
| | | | | | | | | | named A node of a swarm holding a store keeps some of its neighbours among the members of its own party and of the parties its operator names (`--store-neighbour-parties`), so that a party listing many nodes can't be all of them (`docs/store.md`, Members): its neighbours by the shared graph among those members alone, each as its entry names it, which every node of its party computes alike, with those among all members.
* node: a swarm holding a store has no swarm key, nor protocol writerstv23 hours1-0/+24
| | | | | | | A secret its members share keeps out nobody, and its parties say who syncs; nor does a user write its protocol data, as a node writes none but its own (`docs/store.md`, Members). So `--store-root` and `--store-id` refuse `--swarm-key-file`, `--swarm-key-create` and `--protocol-writers`.
* node: the party a node of a swarm holding a store is oftv23 hours1-8/+66
| | | | | | | | | A node's group is its operator's, in its configuration (`docs/store.md`, Members): `--store-party NAME`, which `--store-root` and `--store-id` need, a party's name as the federation spells one. The node keeps it with its store (`Holding::party`), to name it in its entry and its handshakes. The options of a node of a swarm holding a store (`--store-file`, `--store-checkpoint`, `--store-party`) set without either are refused together.
* federation: a pinned checkpoint, found in the documenttv24 hours1-0/+20
| | | | | | | | | | | Once a store moved to a checkpoint, a node reading it from the root could take what was grown anew from the root since, by keys of versions long replaced: so its operator pins the checkpoint (`--store-checkpoint`, by its ID), and the node reads its store from there whenever it starts (`docs/store.md`, Pinned checkpoints). It finds it in its document: at heads a proposal's version names, built from their history read from the root, as any node builds the checkpoint it moves to (`Store::checkpoint_at`), the one whose ID is pinned. Until the document holds it, the node holds no store, and says so once.
* federation: the store read from the documenttv24 hours1-0/+17
| | | | | | | | | | | | | | | | A node of a swarm holding a store holds the store, read from its document (`docs/store.md`, What the store takes from the document): `federation::held`. Whenever the document changes, a worker reads the events it holds that the store wasn't offered from it, under the document's lock, and offers them to the store without it, each taken as from anywhere: once its dependencies are held, judged at its history. Another document (a drop, a rejoin) is read as it comes, the store going on. The node reads its store anew from its document whenever it starts, from the root, by what is its own of it: the events it refused by what it took before, and those its operator had it drop, which it keeps in a file (`--store-file`), written whenever that changes, so that a store read anew in another order refuses what it refused before. A file that doesn't read stops the node from starting; without one, a restart may take what it refused.
* node: a swarm holding a store, started from its root or joined by its IDtv24 hours1-0/+65
| | | | | | | | | | | | | | | | | | | | Behind the `federation` feature, two options: * `--store-root PATH` starts a swarm holding a store, or goes on with one, from the store's root, as bytes in the file, which the federation must take as a root. With no document to start on, the node builds the genesis change from it, as every node given the root does, and is ready at once; a document to start on must be of the root's swarm. * `--store-id ID` joins one through seeds by its ID, the root's SHA-256 in hex. An empty document of the first epoch takes as its root only that store's genesis change, built again from the root it holds (`document::events::is_genesis`), whatever peers name: the root pin doesn't wait for seeds, nor is disputed. Either names the swarm the node joins, which a state file must remember too, and can't be combined with the other, nor with what makes a new swarm's first change (`--genesis`, `--bootstrap-users`, `--bootstrap-keys`, `--bootstrap-policy`, `--remake`, `--genesis-root`). The root is read as a file of its own kind (`store`), counted among the node's files.
* config: a strict bootstrap policy found as the document reads ittv44 hours1-1/+3
| | | | | | | | A strict `--bootstrap-policy` is refused with `--remake`, but whether it was strict went by its JSON as given, where the node reads the policy as written into the document: a strict policy given as an envelope passed, and its genesis change was refused only once the node had started. Both now read it as written (`policy::as_written`).
* config: a strict swarm starts emptytv46 hours1-4/+12
| | | | | | | | | | | | `--genesis --remake` writes the content as a change of its own before the one recording the first users and `--bootstrap-policy`. With a strict policy, that content change was a time before the policy, on which any member could build a change judged by none. A strict `--bootstrap-policy` with `--remake` is now refused: a swarm strict from its start starts empty, and one started from content turns strict through a strict remake, which keeps only what an operator looked over. A policy that isn't strict starts from content as before.
* swarm: a new swarm's policy recorded in its genesis changetv2 days1-0/+19
| | | | | | | | | | | | | | | | A swarm strict from its start had its policy written by its first user in a later change. A change is judged by the policy at its history, so any member could always add a change whose history is from before the policy: judged by none, needing no signature, taken whenever it comes. Since signed values are read by `seq`, an envelope planted there with the highest `seq` there is can never be followed: a ban, a user, a declaration, for good. `--bootstrap-policy JSON`, with `--genesis`, records the policy in the genesis change, with the first users: then no change of the swarm is from before it. It must be a policy this node knows, and a strict one needs `--bootstrap-keys`, or nobody could sign what decides who may do what.
* document file: a clean stop marked, and `--keep-actor` writes on as the same ↵tv8 days1-0/+12
| | | | | | | | | | | | | | | | | | | | | | actor A node writes as a fresh Automerge actor at each start, so no change number of an actor comes twice: one sent before a crash but not yet appended to the document file would otherwise be made again, differently. An epoch thus gathers a writer per start, and every transfer of its history carries a signature per writer. The document file now says when it holds everything the node wrote: * at a clean stop, after the last append, an empty `Closed` record, only where the file is up to the document's heads (ready, not rejoining); * as a node starts on the file, before anything is written, an empty `Opened` record, so a crash from then on leaves a file without the mark; * the header names the actor the node writes with (`current`). With `--keep-actor` (off by default; needs `--document-file`), a node starting on a file that ends with `Closed` writes on as that actor. A crash, a drop, a switch or a rejoin still starts a fresh one, so an epoch's writers come to one per node plus one per such event. lifecycle.md says so.
* signatures: sign what is senttv9 days1-3/+3
| | | | | | | | | | | | | | | | | | | A node signed its changes no rule signs a while after them (--sign-every 1s): the change left at once, unsigned, and its signature followed on its own a second later, to every neighbour, over every link. A few writes made a cascade of SIGNATURES. Under a policy requiring signatures it signed every change as it was made instead. A node now signs its latest change, if no signature vouches for it, as a sync message takes it (--sign-every sent, the default): the signature leaves in the same message, and goes where the change goes. One signature per message, however many changes it carries, each vouching for those before it: a slow writer's every change is signed, a fast writer's batches are, at no threshold to pick. A policy requiring signatures signs what is sent too, even with `none`. `all` still signs every change as it is made; changes to protocol data, listed paths and ?signed=true writes are signed as they are made, as before. The interval, and the task signing on it, go.
* state: refused writes limited for the node tootv9 days1-1/+1
| | | | | | | | | | | | Review 3, R5: --refused-writes-per-minute bounds each user, but the cost it guards, a document copy under the write lock, is the node's: ten users, or ten accounts of one, are ten times the budget. The node now takes six times a user's limit within a minute in all (refused::NODE_FACTOR); past it, every user with a write refused within the minute is answered 429 untried, until the oldest leave it. A user none of whose writes was refused writes on, so honest writers aren't held up by others' refusals.
* roots: a joiner takes a root once its seeds named ittv9 days1-1/+1
| | | | | | | | | | | | | | | | 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.
* state: limit refused writes per usertv9 days1-0/+12
| | | | | | | | | | A write every node would refuse is rolled back by forking the document at the heads before it, under the write lock, at a cost that grows with the document's history. A user could ask for such writes in a loop. Count each user's refused writes over the last minute. Past --refused-writes-per-minute (default 10), its writes are answered 429 without being tried, until the oldest refusal leaves the minute.
* roots: an epoch's root pinned, and named in every handshaketv9 days1-1/+14
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Review 2, N7, the care it raised: a joining node's empty document took as the first epoch's root whatever dependency-less change came first, from whichever peer it joined through; the first epoch's ID is all zeros, so nothing pinned it. A remake's epoch has its ID, the snapshot change's hash, which the rules hold its root to. * Every node names its epoch's root in HELLO and HELLO_REPLY (the epoch's ID for a remake's, its genesis change for the first; wire version 45). A node whose document starts from another root of the same epoch refuses the handshake, logging it: another history under the swarm's ID, a forged root or a genesis started again. * A joining node with an empty document takes as its root only the one it was given (--genesis-root, new), else the one its peers name, and none while they name different ones (access::screen::RootPin, kept in Screening across documents): one peer hands it another root only if it is all the joiner hears, or never, with --genesis-root. A root refused is listed with the refused, what builds on it with it. * The genesis node logs the root (`The swarm's root`); GET /admin/epochs shows it (`root`). A genesis started again under a remembered swarm ID used to merge with the nodes of it still running; they now refuse it (another root), and the docs say to join them with seeds instead. The epoch's identity stays as it is (generation 0 all zeros): records and epoch metadata name it so, and every comparison of epochs with them.
* remake: no --follow-strict-remakes; a strict remake failing says whotv9 days1-10/+2
| | | | | | | | | | | | | | | | | A strict remake takes a majority of members whose --strict-keys take its manifest's signer: no node votes for one without, so --follow-strict-remakes (1173) goes. A node that doesn't vote still switches once the others commit, as with any remake. So that an operator can tell why one fails: a strict remake aborted for want of a majority (the voting period over, or a majority out of reach) says in its reason (GET /admin/remakes/{id}, and the coordinator's log) which members didn't vote, and that a member votes for one only with its manifest signed by a key of its --strict-keys. Each of those logs why itself (`Not voting for a strict remake`). The sim a_strict_remake_too_few_take: only a takes the manifest; the remake aborts, naming b and c.
* remake: turning a running swarm strict, keeping what an operator signedtv9 days1-0/+25
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Until a swarm is strict, the user a change names is its node's word, so any member could have planted registry entries, policy, bans or user-signed values as any user, plain or signed by a key it put there itself; writing the strict policy trusted all of it as it was. A remake of a new kind, `strict`, turns a swarm strict instead: * Its content is a manifest (access::strict): the swarm, the strict policy, and each value kept at the places values are signed, by the SHA-256 of its JSON, signed by an operator (ssh-keygen -Y sign -n continuum-strict). * Every node builds the next epoch as compaction does, keeping at the signed places only the values the manifest names, as they were at the base, and writing its policy (RemakeKind::protocol, the one kind that changes protocol data). Writes after the base reach the new epoch only by replays, judged by the strict policy. * A node votes for one only with its manifest signed by one of --strict-keys, keys given out of the document; without any, for none (logged once, `Not voting for a strict remake`), unless --follow-strict-remakes. A coordinator proposes only what it would vote for (403). Once a majority commits one, every node switches, as with any remake: refusing to switch would only cut a node off. * GET /admin/strict-manifest gives the manifest keeping everything held now, the values for review and the heads they are at; continuum-signed strict shows them, signs once confirmed and proposes at those heads. The sim a_swarm_turning_strict_through_a_remake: a member plants a registry entry as a manager; the operator's manifest leaves it out; a and b, given the key, commit; c, without, follows; the entry is gone and the policy strict everywhere.
* login: logins by key capped per usertv9 days1-0/+27
| | | | | | | | | | | | Review 6: a node remembers the challenges used until they expire, 10 000 at most, and refused every login by key once full. One user holding a key could make 10 000 logins within five minutes and keep everyone else out. A user may now log in by key at most --key-logins-per-user times (100) on a node within a challenge's lifetime, past which that user waits and others don't; the 10 000 stay as the cap for all users together. The lifetime, five minutes until now, is --challenge-lifetime.
* access: --bootstrap-keystv10 days1-0/+15
| | | | | | | The first users' SSH keys, recorded at genesis with their entries, so a swarm can be strict from its start. Auth plan M7.
* signatures: --sign-everytv10 days1-0/+9
| | | | | | | | Changes left unsigned are vouched for by the node's next signature: --sign-every 1s (default) signs the latest within a second, all signs every change, none only those that must be. Auth plan M5.
* dashboard: own links over the API, and CORStv10 days1-0/+19
| | | | | | | | | GET /admin/dashboard/links/own and its event stream: a node's own links, as LINKS_REPLY carried them, for other members' dashboards with a token. CORS for the members' dashboard origins and --cors-origins, without credentials. Auth plan M3.
* auth: logging in, and tokens as bearerstv10 days1-0/+30
| | | | | | | | | POST /auth/login (by htpasswd or the proxy), /auth/refresh, /auth/logout, GET /auth/whoami; every request may bring Authorization: Bearer instead of a password. --token-lifetime and --session-lifetime. Auth plan M2.
* access: bootstrap users onlytv10 days1-2/+2
| | | | | | | The first users come only from --bootstrap-users; the genesis node warns of htpasswd users that aren't among them. Auth plan M1.
* access: genesis of swarms from before the registrytv10 days1-2/+2
| | | | | | | | Swarms started before the registry keep working without one; the genesis node's options for a registry apply only to new swarms. What tests and migration leave is noted in future-work. Auth plan M1, bootstrap and migration (2.5).
* access: authorization at the APItv10 days1-1/+1
| | | | | | | | | Every request is judged by the registry the node holds: store reads pruned to what the user may read, writes refused where it may not, admin endpoints by protocol capabilities. Without a registry, as before (--protocol-writers for protocol data). Auth plan M1.
* access: first users at genesistv10 days1-0/+22
| | | | | | | | --bootstrap-users gives a new swarm a registry from its first change, each first user with everything; other users may do nothing until added. Without it the swarm has no registry and works as before. Auth plan M1.
* HyParView flood defaulttv11 days1-7/+9
|
* flood disseminationtv11 days1-2/+6
|
* HyParView (slim)tv11 days1-2/+75
|
* plumtreetv11 days1-0/+9
|
* swarm neighbourstv12 days1-1/+1
|
* add stream heartbeattv2026-11-031-0/+15
|
* config: dashboard-url requires dashboard featuretv2026-11-031-1/+11
|
* api: allow listening to Unix socketstv2026-11-021-10/+16
|
* dashboard: double-click opens peer dashboardtv2026-11-021-0/+20
|
* api: allow auth delegationtv2026-11-021-5/+27
|
* we're a replicated document, not KV storetv2026-11-011-1/+1
|
* remake: decouple grace time from node's keepalivetv2026-11-011-1/+1
|
* LWW everywhere, mostlytv2026-11-011-0/+9
|
* add 7h old electorate testtv2026-11-011-0/+16
|
* electorate window must be at least 7dtv2026-11-011-3/+6
|
* config: use individual transport enable flagstv2026-11-011-64/+140
|
* config: includes load in file ordertv2026-11-011-11/+83
|
* allow creating all key filestv2026-11-011-4/+41
|
* libp2p: autoignore unroutable address rangestv2026-11-011-0/+10
|
* libp2p: add prefer optiontv2026-10-311-0/+10
|
* add peer clock skew warningtv2026-10-311-0/+15
|