aboutsummaryrefslogtreecommitdiffstats
path: root/src/simtest
Commit message (Collapse)AuthorAgeFilesLines
* remake: no --follow-strict-remakes; a strict remake failing says whotv3 days2-1/+66
| | | | | | | | | | | | | | | | | 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 signedtv3 days2-0/+115
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 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 usertv3 days1-0/+2
| | | | | | | | | | | | 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.
* simtest: forged changes, aborts of expired remakes, envelopes of another swarmtv3 days1-0/+185
| | | | | | | | | | | | | | Simulations backing what the review's fixes changed, beyond their unit tests: * a_change_forged_under_another_members_actor (1145): a change made under b's actor at the seq of b's last change, judged by a: refused as forged, b not refused as a whole, b's next write taken. * an_expired_remake_aborted_by_any_member (1150): under the policy, a coordinator gone before it decides; b aborts its remake once it expired a grace period ago, c takes the abort, nothing refused. * a_strict_swarm (1155): a value alice signed for another swarm, replacing the one there, is refused as such.
* envelope: a signed value names its swarmtv3 days1-0/+6
| | | | | | | | | | | | Review 3.1, part of finding 12: a signed value's payload bound path, user, time and prev, but not the swarm. A user with the same name and key in two swarms could have an envelope replayed from one into the other, wherever the path holds no envelope yet (prev ""). The payload now names the swarm (`swarm`), and a node takes an envelope only for its own. /auth/whoami says the swarm, and continuum-signed and the example in api.md sign it. Wire version 44: nodes before this refuse such envelopes, and those after refuse the old ones.
* simtest: the forged write refused by whichever node judges it firsttv3 days1-4/+9
| | | | | | | a_swarm_judging_every_change waited for c's forged write to be refused by a, b and d each. The first to judge it tells c, which drops it before the others may have it: wait for a refusal on any of them, then for c to drop it.
* simtest: refused by whichever node judges firsttv3 days1-10/+18
| | | | | | | | In a_strict_swarm and sealed_values, c's forged writes were waited for to be refused by a and by b. Whichever judges them first tells c, which drops them before the other may have judged them (it waits for their signature, or never gets them): wait for a refusal on either, then for c to drop them.
* access: a node judges its own changes before they leavetv3 days1-6/+88
| | | | | | | | | | | | | | | | | | | | The API checks the path a request asks for; the rules judge everything the change does. Where they disagreed, the honest node's change was refused by every other node, and with signatures required the node was refused as a whole. The plan had both gates run the same judgement. Under a policy, each change a node makes (its own writes and those through the API) is now judged by rules::judge as receivers will judge it, before it is signed or sent; one every node would refuse is rolled back (the document forked at the heads before it, same actor: the change never left) and the request refused with 403 (StoreError:: Refused). rules::judge_held, judging a change the document holds, moves from swarm::refusals to access::rules for both. The simulations that play a member past its own checks write with a helper that bypasses them (forge). Review finding 3 (the same judgement at both gates).
* access: an epoch's root is never droppedtv3 days1-0/+33
| | | | | | | | | | | | | | | A REFUSALS naming the swarm's first change made the node receiving it judge that change again in a document that isn't empty, refuse it as "a change without dependencies that isn't the epoch's root", and drop it with everything built on it: its whole document. The first epoch's root is now the first change a document holds, as it comes to an empty one or as it is in one; a change judged again on a peer's word is never refused for having no dependencies; and drop_taken refuses to drop an epoch's root, or anything that would leave nothing kept, logging an error instead. Review finding 1 (critical).
* simtest: members against the rules, and a policy unknowntv4 days1-0/+102
| | | | | | | | A member writing past its API's checks is refused, told, drops its change and is taken again; a node under a policy it doesn't know takes no writes and syncs on. Auth plan M6 (tests).
* swarm: changes taken unjudged, dropped (REFUSALS)tv4 days1-9/+83
| | | | | | | | | A node refusing changes a peer brought tells it which broke a rule; the peer judges them itself, and if its rules refuse them too, drops them with all built on them (its document forked without them, a fresh actor), quarantining its own writes among them. Wire version 42. Auth plan M6 (rejoin on taint).
* access: members refused as a wholetv4 days1-0/+9
| | | | | | | | | With signatures required, a member whose own change broke a rule is refused as a whole: sent nothing, shown in /peers (refused), in stats (sync.refusedPeers) and on the dashboard, until a change of its is taken again or the epoch changes. Auth plan M6 (diverged standing).
* simtest: sealed valuestv4 days1-1/+81
| | | | | | | A value sealed for its declared readers goes everywhere; one sealed for a stranger too, or plain, gets nothing past the others. Auth plan M8.
* simtest: a strict swarmtv4 days1-1/+154
| | | | | | | | Signed values everywhere, carried over by a remake and replaced after it; a member writing the registry or a signed path plain gets nothing past the others. Auth plan M7.
* access: --bootstrap-keystv4 days2-3/+3
| | | | | | | The first users' SSH keys, recorded at genesis with their entries, so a swarm can be strict from its start. Auth plan M7.
* simtest: the policy, and a remake under ittv4 days2-0/+165
| | | | | | | | A swarm judging every change: honest writes everywhere, a joining node registers, a forged write stays where it was made; a compaction under the policy refuses nothing honest. Auth plan M6.
* simtest: signed changestv4 days2-1/+115
| | | | | | | Every change vouched for on every node within a second; a forged signature vouches for nothing. Auth plan M5.
* signatures: on their own (SIGNATURES)tv4 days1-3/+6
| | | | | | | Signatures no sync message took go on their own within a second, to each peer not sent them yet (wire version bumped). Auth plan M5.
* signatures: kept in the document filetv4 days1-0/+1
| | | | | | | A node's signatures are saved with its document (--document-file) and loaded with it. Auth plan M5.
* signatures: --sign-everytv4 days1-0/+1
| | | | | | | | 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.
* signatures: changes signed by their nodetv4 days1-1/+2
| | | | | | | | | | Every node signs the changes it commits with its node key, an Ed25519 signature over the change's hash, kept beside the document. One signature on an actor's latest change vouches for its earlier ones. Protocol data and paths listed in _continuum/access/signed are signed, and writes with ?signed=true. Auth plan M5.
* dashboard: without LINKS; LINKS removedtv4 days4-268/+3
| | | | | | | | | The dashboard reads every member's links from the members themselves; LINKS and LINKS_REPLY, swarm::links and their wire tags go (wire version bumped). Nodes the browser can't reach are drawn from what the reachable ones measure. Auth plan M3.
* dashboard: own links over the API, and CORStv4 days1-0/+1
| | | | | | | | | 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 bearerstv4 days1-0/+3
| | | | | | | | | 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: first users at genesistv4 days1-0/+1
| | | | | | | | --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.
* soak plumtree links along the waytv5 days2-4/+61
|
* soak neighbours and settled linkstv5 days1-0/+29
|
* HyParView flood defaulttv5 days1-2/+2
|
* flood disseminationtv5 days1-0/+1
|
* HyParView (slim)tv5 days4-9/+314
|
* bench repeattv5 days1-7/+81
|
* bench eager tree depthtv5 days1-3/+52
|
* bench eager link RTTstv5 days1-7/+40
|
* plumtreetv5 days2-5/+75
|
* bench several scenariostv5 days1-3/+5
|
* fix simtest clock off proposer waitstv5 days1-0/+13
|
* soak records by settv5 days1-2/+6
|
* indirect probestv5 days1-3/+6
|
* partition registrations testedtv5 days1-0/+64
|
* trees at runtimetv5 days1-0/+8
|
* soak quiet after recordstv5 days1-2/+23
|
* soak counts recordstv5 days1-8/+23
|
* soak with churn testtv5 days2-5/+243
|
* bench waits for recorded linkstv5 days1-0/+17
|
* bench writes configurabletv5 days1-8/+17
|
* sent hashes elsewhere measuredtv5 days1-6/+14
|
* simtest: cut coordinator before its committv5 days1-0/+11
|
* clock skew wait longertv6 days1-3/+8
|
* sent hashes measuredtv6 days1-0/+24
|
* tree views measuredtv6 days1-0/+95
|