Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions AGENTS.md
Original file line number Diff line number Diff line change
Expand Up @@ -76,4 +76,7 @@ Keep these properties. [TRUST.md](TRUST.md) and [SECURITY.md](SECURITY.md) expla
- The app key can cast, react and follow, and nothing else. It expires, and it revokes itself
without the recovery phrase.
- A recovery phrase is used in memory only. It is never written to disk or sent anywhere.
- A charter changes only when more than half of its members like a proposal
(`src/core/votes.ts`). Each passed change keeps the signed likes, so anyone can recount it,
and a log whose majority cannot be re-checked is used only after the person says so.
- Every `./outpost` command stays safe to run twice.
52 changes: 51 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -124,6 +124,9 @@ flowchart LR
Join follows its members; Leave drops the lens and keeps your keys, follows and posts. A census
panel shows members, active members, casts per day and the apps members post from, all
computed from your node. Examples are in [examples/](examples/).
- **Society votes.** Members change their charter by liking a proposal, in any Farcaster app.
It passes when more than half of the members have liked it, and anyone can recount it from
their own node. See [Society votes](#society-votes).

- **Every message checked.** The client checks the hash and signature of every message it reads,
and that the signing key belongs to the author, before showing it. A node that alters or makes
Expand All @@ -143,6 +146,44 @@ Which accounts can post from Outpost:
| An account whose owner key is in a browser wallet | "My account's owner key is in a browser wallet". |
| A test account's recovery phrase | "I have a test account's recovery phrase". |

## Society votes

Members add or remove members and moderators by vote. Four rules (`src/core/votes.ts`):

1. A proposal is a member's cast that names the charter's current version and lists the changes,
each account as a mention.
2. An approval is a member's like on it, from any app. Once a client has seen it, it counts for
good.
3. It passes when more than half of the members of that version approve. Leaving needs only your
own approval.
4. The charter becomes a log: the founder's signed charter, then each passed proposal with the
signed likes that passed it. A log that branches is shown, never merged.

There are no deadlines: Farcaster timestamps are set by the author and can be backdated, so a
"closes on Friday" rule could not be checked afterwards. A proposal stops counting once another
passes, because it names an older version.

```
./outpost cli charter propose society.log.json --add dwr --remove 1234 # posts and approves it
./outpost cli charter proposals society.log.json # adds what passed to the file, lists the rest
./outpost cli charter verify society.log.json # recount every amendment from your node
./outpost cli charter announce society.log.json # reply under the proposal with the result
./outpost cli charter import theirs.json society.log.json # take a newer log from a member
```

A plain founder-signed `charter.json` is a log with no amendments yet. The web client does the
same in the Society card: open proposals with their approvals, Approve, Propose a change,
Recount, and Download log.

To try it without mainnet accounts, `npm run build && node --import tsx test/votes-demo.ts` runs
a fake node with a 5-member society and an open proposal, and prints the steps.

Limits: votes are public; members who stay silent count as "no", so a society freezes if half
of its members go quiet (they can leave, or the founder can start a new charter); a recount
labels approvals whose keys were revoked since, and says so when a majority rests on them; such
a log is only used after you say so (`--trust-unrecountable`, or a prompt in the web client).
What a recount proves is in [TRUST.md](TRUST.md#what-a-society-vote-proves).

## Share your node (society mode)

One node can serve a whole community. Members pay nothing and use their own accounts; their app
Expand Down Expand Up @@ -204,6 +245,14 @@ To use the client from a phone, `./outpost client --phone` serves it from your s
posts always show in Outpost.
- App labels come from the key that signed each cast. Keys that people signed for themselves all
show as "own key", and a cast whose key is no longer listed shows as "unknown key".
- A key removed since keeps its earlier casts on the network (Snapchain engine V14 and later).
For an onchain key, Optimism shows it was the author's, so those casts are shown, marked
"key revoked since". A gasless key leaves no record once revoked, so its casts look like
someone else's key: they are held back as "key not listed", and you can show them, marked.
Optimism records no removal time, and the cast's own date is signed by the key, so the client
cannot tell a cast signed before the removal from one backdated later. An honest node refuses
the late ones; someone holding a leaked, removed key and running a dishonest node could serve
one, and it would show marked the same way.
- Casts you write are text up to 1,024 bytes (the limit for a normal account) with up to 4
embedded URLs. There is no image upload, and an @name you type stays plain text; it does not
become a mention. There is no notifications view.
Expand Down Expand Up @@ -245,7 +294,8 @@ VOUCHER.md checklist and draft cast for people who vouch for a run
AGENTS.md rules and step checkpoints for AI assistants that run Outpost for someone
infra/ cloud-init, node setup, snapshot loader, phone access, society mode
src/core/ protocol code: node HTTP client, message checks, accounts, app keys,
writes, feed, app attribution, charters, census (Node and browsers)
writes, feed, app attribution, charters, census, society votes (Node and
browsers)
src/cli/ command-line client
src/web/ web client
src/server/serve.ts local server for the web client, forwards /v1 to the node
Expand Down
26 changes: 26 additions & 0 deletions TRUST.md
Original file line number Diff line number Diff line change
Expand Up @@ -125,6 +125,32 @@ the URL, not the image, so a host can swap the image without changing the signed
A picture cannot change a message or post anything. Only https URLs are loaded, and no referrer
is sent. Untick "Show pictures" above the feed to stop these requests.

## What a society vote proves

A passed amendment is kept in the charter log with the signed proposal and the signed likes that
passed it (`src/core/votes.ts`, tests in `test/votes.test.ts`). A recount (`charter verify`, or
Recount in the web client) checks, from the reader's own node and key sources:

- every signature and hash, so a changed byte anywhere in the log fails;
- that the proposal names the version it changes, and that each version follows the last;
- that the proposer and every approver were members of that version, each counted once;
- that every like is a mainnet like of that exact proposal, signed by a key of the account that
may sign likes: an onchain key, or a gasless key whose scope includes likes (Snapchain refuses
other likes, but a hand-made log could contain them);
- that more than half of the members approved.

It does not prove when anyone voted: Farcaster timestamps can be backdated, which is why votes
have no deadline. It cannot re-check a key that was revoked after the vote. Since Snapchain
engine V14 a removed key's old messages stay on the network, so such an approval may be
genuine, but nothing shows it was signed before the key went. A recount labels these approvals,
and says "not recountable from scratch" when the majority rests on them. The client that
accepted the amendment at the time checked those keys then, and keeps its own log. A log from
someone else with such an amendment is only taken after the reader confirms it.

A host cannot vote for a member: a like needs the member's key. A host's node can hide likes or
proposals from a member's view, which delays a pass but cannot fake one. A second log built
from the same founder's charter is shown as a fork, never merged.

## What the gate enforces

The gate (`src/server/gate.ts`, tests in `test/gate.test.ts`) sits between the web server and
Expand Down
7 changes: 7 additions & 0 deletions site/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -342,6 +342,7 @@ <h2 id="different">What is different about it</h2>
<li><strong>Every message is checked.</strong> Before showing a message, the client checks its hash and signature, and that the key that signed it belongs to the author. What it shows is rebuilt from the signed bytes, so a node cannot alter a message or slip anything into it unnoticed.</li>
<li><strong>One node for a whole society.</strong> Members of a society can share one node. Each gets their own access token and rate limit, and their app keys stay in their own browsers.</li>
<li><strong>Societies as signed files.</strong> A <a href="#g-charter">charter</a> lists a society's members, which apps and channels count, and its code of conduct. Load one to read the society's feed. Leaving is one tap, and a census of its activity is computed on your node.</li>
<li><strong>Societies that change by vote.</strong> Members add or remove members by liking a proposal, in any Farcaster app. It passes when more than half of them have liked it, and anyone can recount it from their own node (<a href="#t-society">step 7</a>).</li>
</ul>
</section>

Expand All @@ -355,6 +356,7 @@ <h2 id="gaps">Known gaps</h2>
<li><strong>Accounts made in the Farcaster app cannot post yet.</strong> The app keeps their custody key. Its own "approve a connected app" flow would add a key with full access and no expiry that Outpost could not revoke; supporting it, clearly labelled, is next. Reading needs no account. To post today, use an account whose custody key is in your own wallet, or create one on a society node (below).</li>
<li><strong>No account? A society can pay for one.</strong> With <code>./outpost sponsor on</code>, a society node's members create a Farcaster account in the client in about a minute: their browser makes the key and the society pays the $0.20 fee, so they need no ETH, invite code or X account. Without a sponsor, Outpost creates no accounts.</li>
<li><strong>Not built yet:</strong> direct messages, channel pages, notifications, image upload and mentions. Direct messages and channel membership are not part of the protocol: they live on the Farcaster app's servers, which a client that reads only from your node does not use. A <a href="#g-charter">charter</a> can limit a feed to channels.</li>
<li><strong>Society votes have not run on mainnet yet.</strong> They are tested against a local test node and in a real browser, not yet with real accounts. Votes are public, and members who stay silent count as "no".</li>
<li><strong>The server costs money while it exists.</strong> About $10 a day on DigitalOcean, whether or not you use the client. For a server Outpost rented, <code>./outpost destroy</code> stops the bill, and <code>--watchdog</code> deletes it for you while the watchdog runs on your computer. A server you brought yourself you stop or delete at its provider.</li>
</ul>
</section>
Expand Down Expand Up @@ -680,6 +682,11 @@ <h3 class="step-h" id="t-society"><span class="n">7</span>Societies: a charter f
casts 1071
casts_per_day 153.0</pre>
<p>A charter is a lens, not a wall. It changes what you see and whom you follow. It cannot stop anyone posting, and it hides nothing from anyone else.</p>
<p>Members change the charter by vote. A member posts a proposal, such as adding someone, and the others approve it by liking it, in any Farcaster app. It passes when more than half of the members have liked it; leaving needs only your own like. There are no deadlines, because Farcaster timestamps are set by the author and could be backdated. Each passed change is kept in the charter file with the signed likes, so anyone can recount it from their own node:</p>
<pre class="cmd">./outpost cli charter propose society.log.json --add dwr
./outpost cli charter proposals society.log.json
./outpost cli charter verify society.log.json</pre>
<p>In the client, the Society panel shows open proposals, how many members approved each, and buttons to approve, propose, and recount. This has not run on mainnet yet (see <a href="#gaps">Known gaps</a>).</p>
</section>

<section class="step" aria-labelledby="t-share">
Expand Down
Loading
Loading