Skip to content

0.75.0

This release closes a way for an agent to make itself a tower or a train by editing its own files.

A session’s own files no longer make it a tower or a train: its role record and its saved entry only claim the role, and the tab Herdr lists it in proves it.

Todo #131, from review finding SB4R-F003 (a pre-existing trust in the role record, found while the train’s session guard was reviewed).

  • The problem. A session’s role record (roles/<hash>.json in the state folder) and the straw-boss entries of its session file are files its own shell can write. A member, a main, or a train that wrote {"role":"tower"} into its record, or a tower entry into its session file, started as a tower at its next /reload, /resume, or restore: it took the workspace’s tower token and the tower’s tools, or, beside a live tower, closed its own tab as a yielding tower does. A saved train entry or a train record did the same for the train role.
  • A record and an entry claim; Herdr proves. A session is a tower only when its process was started as one (STRAW_BOSS_ROLE=tower, or a tower earlier in the same process), or when Herdr lists its pane in a tab labelled with the tower glyph where no other pane runs an agent (the label proves the tab, not the pane: a session in a second pane of the tower’s tab is no tower). A train’s entry or record counts only in the tab labelled train <MMDDx> for its code, and at a /reload the entry must also equal the sb_train token its pane kept, since the label carries neither the project nor the year. The label is what a Herdr restore keeps of a tab Straw Boss made, no file holds it, and the sb server already seats its own towers by it (spec §29, with the reason the server’s word was not chosen).
  • No proof, no role. A claim Herdr does not prove starts a member (a train: no train), with one warning that names the file and the tab. A tab list Herdr fails to answer proves nothing either way: the start stays unplaced and is asked again, and nothing joins meanwhile.
  • The labels are Straw Boss’s own. boss_rename and a main’s label in boss_open_main refuse the tower glyph, the head tower’s glyph, and train <MMDDx>.
  • A pop holds the stash to the same rule. /boss pop starts a tower only for a pane the manifest names a tower alone in a tab labelled with the tower glyph, as a stash records one. A tower named anywhere else comes back a member, and the pop says so in one warning.
  • The server. A roles/ record with role tower becomes a tower service in a tower tab, or, in a tab without the glyph, only for a pane that carries the live tower’s sb_role=tower mark and runs the record’s session file. The record and the file alone no longer do: the pi in that pane would have been given a tower run at its next start.
  • A train’s start. A session with a sign of a train whose role is not settled yet (Herdr has not answered for its pane or tab) joins nothing early: /boss and a subagent call are refused until it is, where before they could publish a train’s pane as a member and promote it.
  • A tower’s session resumed outside a tower tab is a member. /resume or pi --session of a tower’s session file made a tower in any tab; it now does so only in a tab labelled with the tower glyph.
  • A renamed tab is not proven after a restore. A resident tower or a train whose tab you renamed away from its label comes back a member after a Herdr restore (a /reload of a tower started as one keeps it). The server’s own tower seat already had this limit.
  • A main is unchanged. Nothing outside its files survives a restore for a main (its tab’s label is its own name), so its record stands on the checks it had: the newest record of its tab, in a new terminal. A forged main record gives what a member may take by itself, except that at a real restore it can win the tab over the recorded main; that residual is accepted and recorded in the spec.
  • The boundary. The proof is against files a session can edit. A model that runs Herdr commands as you can rename a tab or open a tower tab itself, which no same-user guard prevents. STRAW_BOSS_ROLE is outside the guard as well: a pi started with STRAW_BOSS_ROLE=tower is a tower with no further proof, and any shell can set it. After a Herdr restore a train’s tab proves its short code only, not its project or year.