carlos / platform Public

docs, census: runbook and plan for this round; census re-proposed

Runbook: tenant backfill and ses:ListTenantResources, splitting
KEYLINE, the tenant-send proof without the key on the command line,
restarting the mailer after a platform roll, and switching every app
off before rolling the console back. Plan: G6 ruled, G1/G2/G5/G7/G8
built to recommendation, abort criteria for the watch, and the
one-shot note. Census claims: seven statusLoop sites, the verb's
switch read and bound, cmdVars; the arm probe key.

Fable P2-10; Astra L1.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Paul Campbell pushed by paul@keymail.dev c49e363514ce9fc2c03d0da470911752377d9b3a parent 9901352
7 files changed, +92 −35
  • docs/mailer-runbook.md +41 −6
  • docs/superpowers/notes/census-claims-platform-mail-submission.tsv +4 −3
  • docs/superpowers/notes/census-proposal-platform-mail-submission.md +4 −2
  • docs/superpowers/plans/2026-11-13-platform-mail-submission.md +19 −8
  • internal/provision/platform_mail_submission_census_test.go +7 −1
  • internal/provision/testdata/plan14-root-reads-chain.tsv +1 −1
  • internal/provision/testdata/plan14-root-reads-platform-mail-submission.tsv +16 −14

CI passed — run details

diff --git a/docs/mailer-runbook.md b/docs/mailer-runbook.md
index 4dda09d70..423e54a19 100644
--- a/docs/mailer-runbook.md
+++ b/docs/mailer-runbook.md
@@ -32,6 +32,12 @@ scoped approval"): account, region, resources, permissions, cost, cleanup.
named `carlos-mailer-*`, and SES reports that caller from its own account.
- **Event ingest is on.** A send always names a configuration set, and a
deployment with no SNS topic has none, so every send would be refused.
+- **Tenants.** Whether the tenant association backfill (spec §9 item 3) has
+ landed. If any app sender to be switched has a `TenantARN`, the console's
+ control-plane role needs `ses:ListTenantResources`: without it the switch
+ door cannot confirm the sender's identities and configuration sets are
+ associated with its tenant, and refuses ("Can't confirm this app's SES
+ tenant associations"). That policy is outside this repository.
## 1. Create the IAM user and its policy (tofu)
@@ -88,7 +94,12 @@ echo "${KEYLINE%% *}" # the key id only
```
`KEYLINE` is `<key id> <secret> <created>`, tab-separated, which the key file
-accepts. Keep it in that shell only: never in a file in a repository, an SSM
+accepts. Split it, for the tenant check below, without printing the secret:
+
+```sh
+IFS=$'\t' read -r KEY_ID KEY_SECRET KEY_CREATED <<<"$KEYLINE"
+```
+ Keep it in that shell only: never in a file in a repository, an SSM
parameter, the bucket, `user_data`, a ticket or a chat. Paste it into each
box in step 3, then `unset KEYLINE` and clear the clipboard. If you print it
instead, clear the terminal's scrollback afterwards.
@@ -102,9 +113,9 @@ The key file holds one line per key:
`#` comments and blank lines are ignored. At most two keys (IAM's limit per
user); the mailer signs with the one whose `created` is newest.
-## 3. Arm each box that hosts the apps' routes
+## 2b. Prove a tenant-attributed send (once, before the first switch-on)
-**Before the first switch-on, prove a tenant-attributed send.** AWS's
+AWS's
service reference lists only identity and configuration-set as resources of
`ses:SendRawEmail`, the policy also grants `tenant/carlos-*/*` (as the
console's own does), and §9.0's spike never sent with `TenantName`. So, under
@@ -113,7 +124,7 @@ key, from a sender whose record has a `TenantARN`, to the SES mailbox
simulator:
```sh
-AWS_ACCESS_KEY_ID=<key id> AWS_SECRET_ACCESS_KEY=<secret> AWS_REGION=<ses region> \
+AWS_ACCESS_KEY_ID="$KEY_ID" AWS_SECRET_ACCESS_KEY="$KEY_SECRET" AWS_REGION=<ses region> \
aws sesv2 send-email \
--from-email-address <from>@<a domain verified in ses_region> \
--destination ToAddresses=success@simulator.amazonses.com \
@@ -126,8 +137,11 @@ aws sesv2 send-email \
It must answer a `MessageId`. An `AccessDenied` naming a tenant ARN means
the policy's tenant resource is wrong; one naming nothing else means the
policy needs another resource. Fix the module and re-apply before any
-switch-on; do not widen the policy by hand. Use the key from a shell
-variable as in step 2, not typed, so it stays out of history.
+switch-on; do not widen the policy by hand. The key comes from the shell
+variables split in step 2, never typed on the command line, so it stays out
+of history. `unset KEY_ID KEY_SECRET KEY_CREATED` afterwards.
+
+## 3. Arm each box that hosts the apps' routes
Fixed boxes, and every current group box.
@@ -221,6 +235,27 @@ A key file that stops loading (a bad line, the wrong mode) makes the mailer
refuse every send and fail its health check until it loads again: fix the
file, nothing else is needed.
+## 5b. After a platform roll
+
+The roll replaces the `carlos` binary, and a running mailer keeps the old
+one until it restarts. On every armed box, after the roll:
+
+```sh
+sudo systemctl restart carlos-mailer.service
+sudo journalctl -u carlos-mailer --no-pager | tail
+```
+
+A box whose mailer is not armed has nothing running to restart.
+
+## 5c. Rolling the console back past this build
+
+Switch every app off first (`carlos email submission off --app <app>`), then
+roll the console back. A console from before this build does not know the
+app sender's `submission` and `pause` fields (written `omitempty`), and drops
+them the next time it writes the sender: a switched app would lose its
+switch in the record while its bundles still hold only the From, and its
+instances would have no working channel.
+
## 6. Disarming a box
```sh
diff --git a/docs/superpowers/notes/census-claims-platform-mail-submission.tsv b/docs/superpowers/notes/census-claims-platform-mail-submission.tsv
index 1179c52ad..b909988f0 100644
--- a/docs/superpowers/notes/census-claims-platform-mail-submission.tsv
+++ b/docs/superpowers/notes/census-claims-platform-mail-submission.tsv
@@ -9,7 +9,7 @@
# mail_cli.go:printEmailStatus: the `carlos email status` printer reads the pause from the reply's new optional `pause` block (kind, at), per sender too, and falls back to `active` and provisioned.pause_kind from an older console (emailPauseOf, a pure helper). apiEmailReply and apiEmailSender gain one optional field each. API mode only, run by a person against the console; no read of box state, no root read added
#
# Task 3 (mailer unit, user, socket, peer rule).
-internal/host/agent.go:statusLoop Task 3 (plan gap G6 (b)): the status tick also fills Probes.MailerArmed from mailerArmed(mailwire.MailerSocket, 2s): a stat of /run/carlos-mailer/mailer.sock and, only when it is a socket, GET /v1/health on it. The agent (carlos-edge.service, user carlos), not root; reported in the private BoxMetrics block only. The same six sites; no store request, no read of /etc/carlos-mailer (which uid carlos cannot traverse).
+internal/host/agent.go:statusLoop Task 3 (plan gap G6 (b)): the status tick also fills Probes.MailerArmed from mailerArmed(mailwire.MailerSocket, 2s): a stat of /run/carlos-mailer/mailer.sock and, only when it is a socket, GET /v1/health on it. The agent (carlos-edge.service, user carlos), not root; reported in the private BoxMetrics block only. The same seven sites; no store request, no read of /etc/carlos-mailer (which uid carlos cannot traverse).
internal/host/mailerreport.go:mailerArmed Task 3, new: the agent's MailerArmed probe. Stats the constant socket path and dials it for GET /v1/health with a 2 s timeout; true only on a 200. Runs in the agent as carlos, never as root; the path is a constant, in a root-owned 0750 root:carlos directory nothing a tenant or an app can write. Answers a bool into the private status block.
internal/host/bootstrap.go:bootstrapWithGroup Task 3: the sysusers.d/carlos.conf it writes is now the constant sysusersConf, which adds "u carlos-mailer - \"CARLOS mailer\" - /usr/sbin/nologin" ahead of the existing "g carlos-sockets -" line, so the tmpfiles line naming group carlos-mailer resolves on a box whose confs arrive by a staged-tree refresh. Constant text, no input; no read added.
internal/host/bootstrap.go:const tmpfilesConf Task 3: two constant lines, "d /run/carlos-mailer 0750 root carlos -" (the mailer's socket directory, beside /run/carlos-control and shaped like it) and "d /etc/carlos-mailer 0750 root carlos-mailer -" (the key directory, which uid carlos cannot traverse). Root creates two root-owned directories; no file inside either is created, owned or seeded (the key is the operator's, by hand). No input; no read added.
@@ -31,12 +31,12 @@ internal/host/units/carlos-mailer.service:external Task 3, new: runs /opt/carlos
internal/status/snapshot.go:CollectBox Task 3: copies Probes.MailerArmed into BoxMetrics.MailerArmed (json mailer_armed, omitempty; private, like Layout) and counts it in the condition that builds Metrics; the same 28 sites, no read added.
#
# Task 4 (the verb at both bind sites, CARLOS_MAIL agent-owned).
-internal/activator/backend_exec.go:ExecBackend.controlMount Task 4, new: the one composer of a control socket's verbs, for both bind sites. Mounts the schedule verbs and GET /updates exactly as the two inline copies did (same conditions, same host, token reader and write fence), and POST /v1/mail (mailsubmit.Mount) under its own condition, b.Mail != nil. Reads rt.Host and passes the route to Mount; returns nil when nothing is mounted. The agent (carlos-edge.service, user carlos), not root.
+internal/activator/backend_exec.go:ExecBackend.controlMount Task 4, new: the one composer of a control socket's verbs, for both bind sites. Mounts the schedule verbs and GET /updates exactly as the two inline copies did (same conditions, same host, token reader and write fence), and POST /v1/mail (mailsubmit.Mount) under its own condition, b.Mail != nil. Reads rt.Host and passes the route to Mount; returns nil when nothing is mounted. The agent (carlos-edge.service, user carlos), not root. Fable P2-9: passes b.MailSwitch to mailsubmit.Mount. No read added.
internal/activator/backend_exec.go:ExecBackend.spawnChildFrom Task 4: the inline mount (Timers, UpdatesReader) is replaced by b.controlMount(rt, tokenReader, n): the same verbs under the same conditions, plus the mail verb when b.Mail is set. The three rt.Host reads move into controlMount; the route is passed whole. Agent, not root; nothing else changes. Task 6: also calls warnUndeclaredMailBuild with the route and the version being spawned (a log line and an instance event, never a refusal).
internal/activator/prepare.go:ExecBackend.listenControl Task 4: the same replacement as spawnChildFrom, with gen as the write fence's generation, so the nested and rootfs listener mounts exactly what the flat one does. Agent, not root.
internal/activator/backend_exec.go:ExecBackend.agentOwnedVars Task 4: also decides CARLOS_MAIL through mailSubmits: set to "submit" only when the control socket bound, the verb is mounted, the app sender's switch is on and the route is Provisioned; stripped otherwise, a tenant-supplied value from fileEnv included. agentOwnedNames and moves.AgentOwnedVars gain it as a pinned pair. Only narrows what a tenant's files can set. Agent, not root.
internal/activator/backend_exec.go:ExecBackend.mailSubmits Task 4, new: the CARLOS_MAIL rule. Reads rt.App, rt.Host, rt.Provisioned and RouteAccount(rt) from the agent's own registry row, and asks b.MailSwitch (the agent's cache of the console-written app sender record, internal/host/mailswitch.go: one bounded Get of apps/<acct>/<app>/email/senders/app.json through the agent's deploy store). Logs once per host at error level for an unprovisioned route of a switched app. Agent, not root; no file read.
-internal/mailsubmit/verb.go:Mount Task 4, new: POST /v1/mail on an instance's control socket. The bearer by the existing verbs' rule (empty or unreadable token refuses everything; SHA-256 constant-time compare); MaxBytesReader(14 MiB), the JSON envelope, base64 raw of at most 10 MiB, 1 to 50 non-empty recipients, a non-empty from, else 400 BAD_REQUEST; at most 2 messages per socket in the agent at once, the next 429 RATE (review round 1, Task 4 P3). Stamps account, app and host from the route the socket was bound for, never from the body, and forwards; a transport error or an answer outside 200/400/403/429/503 is 503 MAILER_UNAVAILABLE. Runs in the agent, as carlos; the body is a tenant's and is only decoded and forwarded, never used to name a path, route or account.
+internal/mailsubmit/verb.go:Mount Task 4, new: POST /v1/mail on an instance's control socket. The bearer by the existing verbs' rule (empty or unreadable token refuses everything; SHA-256 constant-time compare); MaxBytesReader(14 MiB), the JSON envelope, base64 raw of at most 10 MiB, 1 to 50 non-empty recipients, a non-empty from, else 400 BAD_REQUEST; at most 2 messages per socket in the agent at once, the next 429 RATE (review round 1, Task 4 P3). Stamps account, app and host from the route the socket was bound for, never from the body, and forwards; a transport error or an answer outside 200/400/403/429/503 is 503 MAILER_UNAVAILABLE. Runs in the agent, as carlos; the body is a tenant's and is only decoded and forwarded, never used to name a path, route or account. Fable P2-9 (2026-11-14): takes the agent's switch read (ExecBackend.MailSwitch) and answers 403 SUBMISSION_OFF before reading the body when the route's app is not switched; a package-level bound of MaxInFlight messages across every socket answers 503 MAILER_UNAVAILABLE. No read added: the switch is the agent's in-memory cache.
internal/mailsubmit/forward.go:SocketForwarder.Send Task 4, new: the agent's client to the mailer: one HTTP POST of /v1/send over a fresh dial of the constant /run/carlos-mailer/mailer.sock, 60 s timeout, answer read to at most 64 KiB and decoded. Runs in the agent, as carlos. The socket's directory is root's; the mailer at the other end is a separate uid.
internal/host/agent.go:runAgent Task 4: sets eb.Mail = mailsubmit.SocketForwarder{} on every box, and eb.MailSwitch to a mailSwitchCache's On that opens the deploy store itself through openDeployStore, retried at most once a minute with an error line until it opens (review round 1, Task 4 P3), armed for the serial-move refresh (armedMailSwitch). Task 6: also sets the ExecBackend's ManifestOf, the same staged-manifest read as TierOf (rt.App and RouteAccount(rt), hence +registry:App and +whole:Route), for the spawn-time check of decision 10, which logs and emits an event and never refuses. Agent, not root.
internal/host/agent.go:fastTick Task 4: on a serial move, after the schedule leg, starts the armed mail switch cache's Refresh on its own goroutine (each read bounded at 2 s, overlapping refreshes skipped). It re-reads the app sender records already cached, through the agent's deploy store. Agent, not root; the tick waits on nothing new.
@@ -61,3 +61,4 @@ cli.go:runShip Task 6: a --mail flag (only "submit" accepted, refused with one l
internal/activator/backend_exec.go:ExecBackend.spawnUnitFrom Task 6: calls warnUndeclaredMailBuild with the route and the version being spawned. Logs and emits an instance event once per (host, version) when the app is switched and the staged manifest does not declare --mail submit; never refuses. Agent, not root.
internal/activator/rootfs.go:ExecBackend.spawnRootfs Task 6: the same warnUndeclaredMailBuild call for a rootfs spawn. Agent, not root.
internal/activator/mailbuild.go:ExecBackend.warnUndeclaredMailBuild Task 6, new: design decision 10's loud log, never a refusal (a refused wake would turn a mail gap into a site outage). Asks the agent's switch cache (MailSwitch) and reads the staged manifest of the version being spawned through ManifestOf (release.ReadStagedManifest, the read TierOf already makes); logs at error level and emits one instance event per (host, version). Agent, not root; reads only what the spawn already reads.
+internal/activator/cmdunit.go:ExecBackend.cmdVars Fable P3 (2026-11-14): a cmd one-shot's environment also strips CARLOS_MAIL, as seedVars does: a one-shot has no control socket, so it cannot submit mail. Only narrows what a run is given; no read added. Agent, not root.
diff --git a/docs/superpowers/notes/census-proposal-platform-mail-submission.md b/docs/superpowers/notes/census-proposal-platform-mail-submission.md
index ffd7b66e8..350853d84 100644
--- a/docs/superpowers/notes/census-proposal-platform-mail-submission.md
+++ b/docs/superpowers/notes/census-proposal-platform-mail-submission.md
@@ -7,9 +7,10 @@ Ruling `census-ruling-platform-mail-submission`. The independent reviewer approv
| `cli.go` `runShip` | body | unchanged (2) | Task 6: a --mail flag (only "submit" accepted, refused with one line otherwise, and refused with --rootfs), set on the manifest in direct-bucket mode and sent to the console in API mode, where a console that does not echo it is refused (ship_mail.go, apimode.go), as --stateless is. A person's ship command; no root read, no box state. |
| `infra/modules/region-host/outputs.tf` `external` | body | unchanged (1) | Task 8: output "mailer_user_name", the user's name or null. Read-only. |
| `infra/modules/region-host/variables.tf` `external` | body | unchanged (1) | Task 8: variable "mailer", an object {ses_region, ses_account_id, deployment_bucket_region, optional deployment_bucket_kms_key_arn} defaulting to null, which creates nothing; validated (AWS region shapes, 12-digit account, KMS ARN or empty). |
+| `internal/activator/cmdunit.go` `ExecBackend.cmdVars` | body | unchanged (2) | Fable P3 (2026-11-14): a cmd one-shot's environment also strips CARLOS_MAIL, as seedVars does: a one-shot has no control socket, so it cannot submit mail. Only narrows what a run is given; no read added. Agent, not root. |
| `internal/host/agent.go` `fastTick` | body | unchanged (1) | Task 4: on a serial move, after the schedule leg, starts the armed mail switch cache's Refresh on its own goroutine (each read bounded at 2 s, overlapping refreshes skipped). It re-reads the app sender records already cached, through the agent's deploy store. Agent, not root; the tick waits on nothing new. |
| `internal/host/agent.go` `provisionTickConfig` | body | unchanged (2) | Task 5: its region, pools and fleet label now come from BoxScopeFromEnv, which is the same three reads moved out unchanged (CARLOS_REGION trimmed, provision.ParseBoxPools(CARLOS_POOLS), and resolveFleetIdentity's label only when its fleet is the one the region places the box on), so the box-local mailer resolves "on this box" by the agent's rule. The ReconcileConfig it returns is field for field what it was. Agent, not root. |
-| `internal/host/agent.go` `statusLoop` | body | unchanged (7) | Task 3 (plan gap G6 (b)): the status tick also fills Probes.MailerArmed from mailerArmed(mailwire.MailerSocket, 2s): a stat of /run/carlos-mailer/mailer.sock and, only when it is a socket, GET /v1/health on it. The agent (carlos-edge.service, user carlos), not root; reported in the private BoxMetrics block only. The same six sites; no store request, no read of /etc/carlos-mailer (which uid carlos cannot traverse). |
+| `internal/host/agent.go` `statusLoop` | body | unchanged (7) | Task 3 (plan gap G6 (b)): the status tick also fills Probes.MailerArmed from mailerArmed(mailwire.MailerSocket, 2s): a stat of /run/carlos-mailer/mailer.sock and, only when it is a socket, GET /v1/health on it. The agent (carlos-edge.service, user carlos), not root; reported in the private BoxMetrics block only. The same seven sites; no store request, no read of /etc/carlos-mailer (which uid carlos cannot traverse). |
| `internal/host/bootstrap.go` `bootstrapWithGroup` | body | unchanged (3) | Task 3: the sysusers.d/carlos.conf it writes is now the constant sysusersConf, which adds "u carlos-mailer - \"CARLOS mailer\" - /usr/sbin/nologin" ahead of the existing "g carlos-sockets -" line, so the tmpfiles line naming group carlos-mailer resolves on a box whose confs arrive by a staged-tree refresh. Constant text, no input; no read added. |
| `internal/host/bootstrap.go` `const tmpfilesConf` | body | unchanged (7) | Task 3: two constant lines, "d /run/carlos-mailer 0750 root carlos -" (the mailer's socket directory, beside /run/carlos-control and shaped like it) and "d /etc/carlos-mailer 0750 root carlos-mailer -" (the key directory, which uid carlos cannot traverse). Root creates two root-owned directories; no file inside either is created, owned or seeded (the key is the operator's, by hand). No input; no read added. |
| `internal/host/bootstrap.go` `privilegedPlan` | body | unchanged (1) | Task 3: one more constant argv, useradd --system --user-group --no-create-home --shell /usr/sbin/nologin carlos-mailer, right after carlos's, behind runPrivileged's existing guard (user.Lookup of the argv's own last word). No input; no read added. |
@@ -41,6 +42,7 @@ Recorded dispositions, which each change must still satisfy:
- `cli.go` `runShip`: legacy, task accepted-legacy. Basis: accepted-legacy;rev3=J4;basis=root-input;rev3=census-ruling-rootfs-apps-1;basis=rootfs Plan 1 Task 9: takes --rootfs, --processes, --hibernate, --jit and --check and hands a rootfs ship to runShipRootfs (ship_rootfs.go) before the binary path; the --notes-file ReadFile moved into shipNoteText (its own row, the same read of the file the person named) and the direct-mode version mint into mintDirectVersion; one read site fewer, none added; Task 12: the --hibernate flag help is RFS-1-C32's new text, the same reads;rev3=census-ruling-edge-asset-cache-1;basis=takes --assets (repeatable), checks the folders with checkShipAssets (release.ValidAssetPaths; refused on a static site) before the mode split, carries them into the API meta (sess.shipAssets) and the direct-mode manifest (shipAssetsBlock), and passes them to runShipRootfs (rootfsShipOpts.assets), which runs the same check and carries them the same two ways; after a direct-mode ship has stored a release declaring folders, directShipAssetGens runs the console ship door's backfill (provision.MintMissingAssetGens: lists the app's record keys and gives each record without an asset generation one, a CAS write in the deployment bucket as the person running the CLI) and fails naming any record it could not mint; read sites unchanged (2), none added;rev3=census-ruling-rootfs-apps-4;basis=adds the repeatable --env flag and refuses it before anything else unless --check is given (shipEnvRefusal, parseShipCheckEnv); the parsed values go into rootfsShipOpts.checkEnv. --env values reach the check's local container runtime as -e argv only, never root, never a box. No read added; read sites unchanged (2).;rev3=census-ruling-stateless-replicas-1;basis=Carry --stateless into binary/API and rootfs ship options; same two read sites, no new read.
- `infra/modules/region-host/outputs.tf` `external`: legacy, task accepted-legacy. Basis: accepted-legacy;rev3=J4;basis=root-input;rev3=census-ruling-region-ha-p3b;basis=Keep fixed outputs through indexed resources, return null for group instance/EIP, and expose group, pinned template, ingress and boot-parameter names. Operator Terraform outputs only; no new box read.;rev3=census-ruling-region-ha-g2-fixes;basis=Expose the module alert topic ARN, null without an alerts topic; no new box runtime read.;rev3=census-ruling-region-ha-g3-fixes;basis=Return the selected existing or module-created alert topic ARN, null when neither input is set. Terraform output only; no new root runtime read.;rev3=census-ruling-managed-fleets-2b1;basis=managed fleets 2b-1 Task 5: three outputs, managed_fleet_user_boundary_arn, managed_fleet_user_path and managed_fleet_bucket_prefix, each null unless managed_fleets_enabled; Terraform outputs for the operator only; no box runtime read is added;rev3=census-ruling-w6-ingress-drain;basis=new output ingress_target_groups: the ARNs joined with commas in fixed mode when set, null otherwise and in group mode; the operator copies it into the box's host.env (CARLOS_INGRESS_TARGET_GROUPS) by hand. Output only; no read added.
- `infra/modules/region-host/variables.tf` `external`: legacy, task accepted-legacy. Basis: accepted-legacy;rev3=census-ruling-console-invite-delivery;basis=tofu on an operator's machine with the operator's AWS credentials (no box unit; no binary embeds the file): main's variables with console_mail_from (validated as one lowercase address) and console_mail_region, both empty by default; no read is added and nothing on a box reads the file;rev3=census-ruling-hunt-account-root-hardening;basis=adds deny_release_key_reads (bool, default true); no read is added and nothing on a box reads the file;rev3=census-ruling-region-ha-p3b;basis=Add default-fixed mode and validated group count, zones, pinned image/release/template, ingress, configuration key and transaction-open refusal. Operator-supplied Terraform values select root boot inputs; no direct box runtime read and no group activation by default.;rev3=census-ruling-region-ha-g2-fixes;basis=Add an empty-default set of additional alert topic ARNs, validating concrete SNS topic syntax and excluding wildcards/subscriptions; operator Terraform input, no box runtime read.;rev3=census-ruling-region-ha-g3-fixes;basis=Add optional alerts_topic_arn with concrete same-region SNS ARN validation and mutual exclusion with alerts_email. The caller owns the existing topic policy and subscriptions; no runtime sink is configured and no new root read is added.;rev3=census-ruling-managed-fleets-2b1;basis=managed fleets 2b-1 Task 5: five variables, managed_fleets_enabled (bool, default false, refused unless mode is fixed), managed_fleets_deployment, managed_fleets_regions (concrete ami/subnet/sg IDs, arm64 types, no ID in two regions), managed_fleet_bucket_prefix (1-24 chars, no reserved prefix, must not cover the deployment, data or staging buckets, disjoint from store_bucket_prefix) and managed_fleet_user_path (literal IAM path, disjoint from store_user_path); store_bucket_prefix and store_user_path gain a validation refusing *, ? or ${ only when managed fleets and object storage are both on; operator Terraform input only; no box runtime read and nothing on a box reads the file;rev3=census-ruling-fixedbox-health-alarms;basis=Add optional health_alerts_topic_arn (concrete same-region SNS ARN validation, empty default); enable_auto_recovery description covers both status alarms. Operator Terraform input; no box runtime read.;rev3=census-ruling-w6-ingress-drain;basis=new variable ingress_target_group_arns (list(string), default [], non-nullable) validated as distinct ELB target group ARNs (arn:aws(-x)*:elasticloadbalancing:<region>:<12 digits>:targetgroup/<name>/<16 hex>); drives the IAM policy and output above. No read added.;rev3=census-ruling-stats-prune-400;basis=new variable enable_analytics_version_prune (bool, default false) driving the policy above; operator Terraform input; no box runtime read
+- `internal/activator/cmdunit.go` `ExecBackend.cmdVars`: legacy, task accepted-legacy. Basis: accepted-legacy;rev3=census-ruling-carlos-run;basis=the agent (/opt/carlos/carlos agent, carlos-edge.service, user carlos): composes the command's environment over the serving generation's launch snapshot; the host comes from the row, never from a tenant file;rev3=census-ruling-stateless-replicas-1;basis=Task 3a: Use the verified generation/launch mode to remove CARLOS_DB after environment merges and omit the binary --db argument where applicable. Existing runtime, layout, secrets and exec gates remain; route reads are mode projection only.
- `internal/host/agent.go` `fastTick`: legacy, task accepted-legacy. Basis: accepted-legacy;rev3=J1;basis=root-route;rev3=PROPOSED-s3-change-index;identity=the agent (/opt/carlos/carlos agent, carlos-edge.service, user carlos);basis=observes the change index before any pass (observeIndex), runs the backstop's requested full pass and a scoped pass for moved app scopes (indexTick), and arms the canary pointer gate on the sweep (canaryPointerGate) only on a tick whose own index observation succeeded; read site unchanged, offset moved;rev3=census-ruling-stateless-replicas-1;basis=Call coordinator Tick on the existing tick before convergence; client renews held terms only at the pinned interval. Existing registry read unchanged. Final review I3: signal the owned renewal worker instead of waiting for its sequential console HTTP calls. Existing convergence and record read unchanged.;rev3=census-ruling-region-ha-p3a;basis=Run the optional desired-role reader on the existing tick after observing the armed change index; no new root path or timer, nil reader is unchanged.;rev3=census-ruling-stateless-replicas-2;basis=Slice 3b: signals the owned replica worker on the existing tick; coalesced asynchronous execution, no timer or bucket scan added. merge of origin/main 7920cccf: Retain main box-role reader pass on the existing tick alongside the replica worker signal; merge-only body change, unchanged read sites.;rev3=census-ruling-restart-new-box-gap;basis=calls the optional restartGain hook (restartGainSeed) once per existing tick before the serial read; no new root path, timer or read kind; nil hook is unchanged;rev3=census-ruling-agent-start-demo-3;basis=Refresh moved notices through the shared watch before normal convergence; no new per-box poll. Census read-site delta: unchanged (1).;rev3=census-ruling-stateless-replicas-4-task1;basis=Signals the owned replica swap worker (armedReplicaDeploy.tick) beside the placement worker on the existing tick; coalesced background pass, no timer, no bucket read. Its transitions go through the console's authenticated /deploy.
- `internal/host/agent.go` `provisionTickConfig`: legacy, task accepted-legacy. Basis: accepted-legacy;rev3=J4;basis=root-input;rev3=census-ruling-ha-p1a-433;basis=the agent (carlos-edge.service, user carlos) and the edges file loop's eligibility: the same CARLOS_POOLS read, now parsed by provision.ParseBoxPools (internal/provision, envelope re-pinned), the one parser boxPools also uses. "@shared" (provision.SharedPoolToken, never a valid pool name) is the shared "" pool; other tokens are literal as before; empty elements and repeats dropped. No read added.;rev3=census-ruling-managed-fleets-1b;basis=managed fleets 1b (Task 4, rule 2): sets ReconcileConfig.FleetBox to the box's own fleet label from resolveFleetIdentity(getenv), only when the identity resolves and region == PlacementTarget(identity.Fleet); otherwise it stays "" (the box admits only unlabelled records). The same environment the fleet loops already read; read sites unchanged (2). Agent config, not root.
- `internal/host/agent.go` `statusLoop`: legacy, task accepted-legacy. Basis: accepted-legacy;rev3=census-ruling-self-serve-moves-1;basis=the agent (/opt/carlos/carlos agent, carlos-edge.service, user carlos): the status tick's context carries the box's lifetime judge; read sites unchanged, offsets moved;rev3=census-ruling-rootfs-apps-2;basis=main's body as of the merge of origin/main 953b9fda (its later changes, regional box names and self-serve moves plan 1 among them, under main's own census rulings), where the tick fills rootfs_ready and rootfs_blocked from armedRootfs.Load().probe, which each tick runs NestedOK's checks and asks the control socket's GET /ready/rootfs (never the store); the same four direct sites;rev3=census-ruling-instance-egress-sizes-328-329;basis=#328 plan 2 Task 11 and #329 plan 3 Task 7: takes root's GET /egress reader and fills p.Egress = egressStatusProbe(egressStatus, routes, provision.PolicyReadStates()) and p.SizeCommittedMiB = sizeCommittedMiB(armedSizeSource.Load(), routes); the two added whole:Route sites are the tick's own registry list handed to those two units (decision rows), which read root's control socket and the activator's memory; no store request added; the four existing sites unchanged, offsets moved.;rev3=census-ruling-fleet-alerts-1;basis=the agent (carlos-edge.service, user carlos): the status tick passes os.Geteuid() to alertDeliveryProbe, which fills AlertDelivery.EngineBeat/EngineBeatWhy from engineBeatArmed (the env value and the euid only, no file access, root refused before the path is looked at), and fills Probes.DiskFullETAHours from diskETAProbe(&processDiskTrend, now), a Theil-Sen fit over the metrics loop's in-memory ring of disk readings; the same six sites, no read added, no store request added;rev3=census-ruling-edge-held-streams;basis=the agent (/opt/carlos/carlos agent, carlos-edge.service, user carlos): the status tick's Probes gain HeldStreams: heldStreamsState(), which calls the edge's in-memory counters function (nil until the edge is ready). No file, bucket or registry access added.;rev3=census-ruling-stateless-replicas-3;basis=Fix round 1 Q20: read the detached in-memory replica snapshot source into Probes.ReplicaCopies on the existing five-minute tick. Existing six direct read sites unchanged. No additional bucket request, changed cadence or app lifecycle action.;rev3=census-ruling-agent-start-demo-3;basis=Report moved capability only when the serving edge reports readiness; report claim-seed support only with CARLOS_DEMO_CLAIM=1. Reads the explicit capability flag from the process environment; no new filesystem or registry read.;rev3=census-ruling-stateless-replicas-4-task5;basis=Task 5 fix round 1 (#511 R16 amendment): the status tick also fills Probes.ApplyFinished from systemApplyFinished(release.OptDir()), an Lstat of root's apply journal <opt>/system/router/journal.json in the root-owned, world-readable state directory: finished only when the journal is absent, any other answer unknown and so unfinished. Round 0: Probes.PrevRelease from prevReleaseOf (carlos.prev and carlos.prev.version, the files withMovesFields already reads). Reported in the private BoxMetrics block; no bucket request or cadence change.;rev3=census-ruling-offline-move-stage-refusals-339;basis=#339: the agent (carlos-edge.service, user carlos): the status tick fills p.OfflineMove = offlineMoveFactsProbe(routes); the added whole:Route site is the tick's own registry list handed to that unit, which under a non-root euid lists the names of root's <opt>/live and nothing else; no store request added.
@@ -86,6 +88,6 @@ New dispositions, which census-propose wrote and the reviewer checks against the
- new `internal/mailsubmit/forward.go:SocketForwarder.Send`: reads +file:ReadAll; written legacy, accepted-legacy, frozen
- new `internal/mailsubmit/verb.go:Mount`: reads +registry:App, +registry:Host, +whole:Route; written legacy, accepted-legacy, frozen
-Seal: `5603979dfa1a34a1b30784d1f9252f20b0ed95c114bde54e8b173f9262fe8f46` → `57fa42c9fe9081d760f641f9ae6f65d850a1748ecfba2f64c6d0142eaf71efcc`.
+Seal: `5603979dfa1a34a1b30784d1f9252f20b0ed95c114bde54e8b173f9262fe8f46` → `98f09a319faffbf4f0ac2ba6598c66f4dd252cec9f71fb5ec9dc08a636f26617`.
Overlay: `internal/provision/testdata/plan14-root-reads-platform-mail-submission.tsv`, appended to `internal/provision/testdata/plan14-root-reads-chain.tsv`.
diff --git a/docs/superpowers/plans/2026-11-13-platform-mail-submission.md b/docs/superpowers/plans/2026-11-13-platform-mail-submission.md
index 37c3431f3..41f5a0ba7 100644
--- a/docs/superpowers/plans/2026-11-13-platform-mail-submission.md
+++ b/docs/superpowers/plans/2026-11-13-platform-mail-submission.md
@@ -30,14 +30,14 @@ Each gap names the task it blocks, the spec text, what the code shows, and a rec
| # | Blocks | Spec says | What the code shows | Recommendation |
|---|---|---|---|---|
-| G1 | Task 1 | Decision 8 and test 8.13: "a cap pause lifts at the day roll; rate, **plan** and manual pauses do not" | `resumeStaleCapPause` (`internal/console/mailcounts.go:176-206`) lifts **cap and plan** pauses at the day roll, and `PauseKindPlan`'s own comment (`internal/mail/mail.go:84-86`) says it lifts like a cap pause. Decision 8 also says "keeping today's pause kinds" | Keep today's behaviour (cap **and plan** lift at the roll). Read test 8.13 as "rate, manual and per-instance do not". Changing plan pauses would be a billing change this design never argued for |
-| G2 | Tasks 6, 7 | §4 "The retry queue stays in the app (rastrillo's existing mail queues)" | rastrillo has **no** mail queue. `mail.Sender.Send` is synchronous (`rastrillo/mail/mail.go:39,153`), and a grep for retry, backoff, outbox and queue in `mail/`, `auth/` and `jobs/` finds nothing | rastrillo's transport retries `503` a bounded number of times inside the caller's deadline and returns `429` as a typed error carrying `Retry-After`, never retrying it hot. Any queue is the app's own. Test 8.10 is met by the typed error plus the bounded retry |
+| G1 | Task 1 | Decision 8 and test 8.13: "a cap pause lifts at the day roll; rate, **plan** and manual pauses do not" | `resumeStaleCapPause` (`internal/console/mailcounts.go:176-206`) lifts **cap and plan** pauses at the day roll, and `PauseKindPlan`'s own comment (`internal/mail/mail.go:84-86`) says it lifts like a cap pause. Decision 8 also says "keeping today's pause kinds" | Keep today's behaviour (cap **and plan** lift at the roll). Read test 8.13 as "rate, manual and per-instance do not". Changing plan pauses would be a billing change this design never argued for **Built to recommendation.** |
+| G2 | Tasks 6, 7 | §4 "The retry queue stays in the app (rastrillo's existing mail queues)" | rastrillo has **no** mail queue. `mail.Sender.Send` is synchronous (`rastrillo/mail/mail.go:39,153`), and a grep for retry, backoff, outbox and queue in `mail/`, `auth/` and `jobs/` finds nothing | rastrillo's transport retries `503` a bounded number of times inside the caller's deadline and returns `429` as a typed error carrying `Retry-After`, never retrying it hot. Any queue is the app's own. Test 8.10 is met by the typed error plus the bounded retry **Built to recommendation.** |
| G3 | Tasks 6, 7 | Decision 10: "When on, no `<P>_SMTP_*` is delivered anywhere"; test 8.1 | The five delivered variables include `<P>_SMTP_FROM` (`EnvNames`, `walk_environment.go:178`). With all five gone, a switched app has **no From address** to put in `from` and `From:` | Deliver one non-secret variable, `<P>_MAIL_FROM` (the sender's `Declared.From`), in place of the five. It goes into the default bundle and every owned environment's bundle: those that exist at the flip, **and every one created while the switch is on** (`mintOwnedEnvironmentMail` delivers it and mints nothing, round 1 P1-1). Releasing an environment removes it. Test 8.1 still holds: no `<P>_SMTP_*` and no AWS key **Ruled by Paul, 2026-11-13 ("yes to all"): as recommended.** Build note (Task 7 correction): the variable is `TrimSuffix(EnvPrefix, "_SMTP") + "_MAIL_FROM"` (`CARLOS_MAIL_FROM` for the default `CARLOS_SMTP`, `DOCS_MAIL_FROM` for `DOCS_SMTP`), which rastrillo reads as `<prefix>_MAIL_FROM`; a prefix that does not end in `_SMTP` refuses the switch. |
| G4 | Task 6 | Decision 10: "**Before §7.4's reap, `carlos email test --submit`** sends through the submit path per route, as proof" | Only the agent can reach an instance's control socket (round 3's own P3). The console has no path to make a route send | Gate the §7.4 reap on **event evidence** instead. The evidence is a per-app, per-day count of Send events **by caller class**, which Task 2 records (`mail_caller_sends`, round 1 P2-1): `mail_events` has no caller column, and every class resolves to sender `app`. The reap needs all three of these:<br>• at least 7 days since the switch;<br>• at least one `mailer` Send for the app;<br>• no `app_user` Send (`carlos-mail-<acct>-<app>`) in the last 7 days.<br>**What this proves:** the app-level SMTP key stopped being used. It does **not** prove that submit works on every route. A route that never sends proves nothing either way, and a route that cannot submit shows up as its app's own failures and the mailer's refusals, not here. `--submit` is left out of this plan **Ruled by Paul, 2026-11-13: as recommended** (no `app_user` send for 7 days, from `mail_caller_sends`). |
-| G5 | Task 8 | §5: the IAM policy is "conditioned on `ses:FromAddress` matching the platform's verified identities, or on `ses:TenantName`" | One fleet-wide user cannot carry a static `ses:FromAddress` list: identities are created at runtime by the console, per account. Terraform cannot enumerate them | `ses:SendRawEmail` on `arn:aws:ses:<mail_region>:<acct>:identity/*` and `configuration-set/carlos-*` only, with no From condition. The mailer's From check is the gate (as §5 already says); IAM bounds the account, region and resource types. Add the `ses:TenantName` `StringLike carlos-*` condition only once §9 item 3's backfill has landed (it would refuse every untenanted send). Round 3's P3 list already names this |
+| G5 | Task 8 | §5: the IAM policy is "conditioned on `ses:FromAddress` matching the platform's verified identities, or on `ses:TenantName`" | One fleet-wide user cannot carry a static `ses:FromAddress` list: identities are created at runtime by the console, per account. Terraform cannot enumerate them | `ses:SendRawEmail` on `arn:aws:ses:<mail_region>:<acct>:identity/*` and `configuration-set/carlos-*` only, with no From condition. The mailer's From check is the gate (as §5 already says); IAM bounds the account, region and resource types. Add the `ses:TenantName` `StringLike carlos-*` condition only once §9 item 3's backfill has landed (it would refuse every untenanted send). Round 3's P3 list already names this **Built to recommendation.** |
| G6 | Task 8, Task 9 | §5: key "armed by the operator by hand", and never through `user_data`, SSM or the bucket | Group-mode boxes are launched unattended by their Auto Scaling group (`group-init.sh.tftpl:312-338`). A new or replaced group box has **no key**, so its mailer never starts and every switched instance on it answers `503 MAILER_UNAVAILABLE` until someone arms it. Every automatic delivery path the spec rules out is one uid `carlos` can read | Ask Paul. Options: (a) switched apps run on fixed boxes only, refused by the door; (b) the box reports "mailer armed" in its status record, the door and an alert read it, and the operator arms each new box (a runbook step per scale event); (c) a separate design for unattended key delivery. This plan builds (b)'s report and alert (Task 3 step 6, Task 6 precondition) because it helps under every option **Ruled by Paul, 2026-11-13: (b).** Group boxes answer `503` until armed by hand; the `mailer_unarmed` alert flags them. |
-| G7 | Task 6 | Decision 10: "**Adopting**, rolling back to, or pinning a build whose manifest lacks the declaration is refused" | Every person-facing change of what a route serves goes through a console door. A box's `carlos adopt` (root) also adopts channel heads that a direct-bucket promote (pinfra scripts) moved, without the console | Refuse at every console door that changes what a route serves (one shared check, and a guard test over the route table). At the box, log loudly and raise an event when a switched app's route starts an undeclared build, as decision 10 already does for wake. **As built (Task 6):** the log is at spawn only, in the agent, on every launch path (flat, unit, rootfs), once per (host, version). An adopted head is caught there, at its first start. The adopt pass itself (`carlos adopt`, root) does not log: it would have to read the app's switch, a new root read of a console-written object, and the plan does not add one. A box-side adopt **refusal** would be new root authority, and the plan does not add it unless Paul asks |
-| G8 | Task 6 | §5 Tenants: "The switch refuses an app whose sender would send with an unassociated tenant" | Nothing records whether an identity or configuration set is associated with its tenant (`DomainRecord`, `internal/mail/domain.go:59-66`). Senders spec §4.2.1's backfill is §9 item 3, still open | The door asks SES live (`ListTenantResources`) through the console's provisioner, only when the app sender has a `TenantARN`. The control-plane role may need `ses:ListTenantResources`. That policy is not in this repo (senders spec §4.2 item 2). A sender with no `TenantARN` sends without `TenantName` and needs no association |
+| G7 | Task 6 | Decision 10: "**Adopting**, rolling back to, or pinning a build whose manifest lacks the declaration is refused" | Every person-facing change of what a route serves goes through a console door. A box's `carlos adopt` (root) also adopts channel heads that a direct-bucket promote (pinfra scripts) moved, without the console | Refuse at every console door that changes what a route serves (one shared check, and a guard test over the route table). At the box, log loudly and raise an event when a switched app's route starts an undeclared build, as decision 10 already does for wake. **As built (Task 6):** the log is at spawn only, in the agent, on every launch path (flat, unit, rootfs), once per (host, version). An adopted head is caught there, at its first start. The adopt pass itself (`carlos adopt`, root) does not log: it would have to read the app's switch, a new root read of a console-written object, and the plan does not add one. A box-side adopt **refusal** would be new root authority, and the plan does not add it unless Paul asks **Built to recommendation.** |
+| G8 | Task 6 | §5 Tenants: "The switch refuses an app whose sender would send with an unassociated tenant" | Nothing records whether an identity or configuration set is associated with its tenant (`DomainRecord`, `internal/mail/domain.go:59-66`). Senders spec §4.2.1's backfill is §9 item 3, still open | The door asks SES live (`ListTenantResources`) through the console's provisioner, only when the app sender has a `TenantARN`. The control-plane role may need `ses:ListTenantResources`. That policy is not in this repo (senders spec §4.2 item 2). A sender with no `TenantARN` sends without `TenantName` and needs no association **Built to recommendation.** |
| G10 | Task 4, Task 9, operator step 8 | Decision 11: rastrillo "fails loudly at boot when a switched app has neither channel" | With `CARLOS_MAIL` set only for `rt.Provisioned` (round 1 P2-2), a **hand-made route** (a registry row with no instance record) of a switched app has neither channel. Its bundle lost the SMTP variables, so rastrillo refuses at boot: **a mail gap becomes a site outage for that route**. Nothing in the door can see such a route, because the box report keys `RouteVersions` by host, not by app (round 2 P2-B; family "one working channel", second round) | **Paul's choice.** The plan as written takes (a), and the copy and the operator check say so.<br>(a) Accept it, with an operator check before switch-on that every route of the app has an instance record (operator step 8), and the outage named in the `email submission on` copy.<br>(b) Add the app to the box report (a host-to-app map) so the door can refuse.<br>(c) Let rastrillo fall back to logged mail rather than refuse at boot, which reverses decision 11's loud failure **Ruled by Paul, 2026-11-13: (a).** The hand-made-route outage is accepted, with the operator check before each switch-on. |
| G9 | Task 5 | §5 Rate: "a per-sender token bucket" | No rate or burst is given | 2 messages a second, a burst of 20, per sender per box, as package constants. Paul to confirm against the deployment's SES send rate **Ruled by Paul, 2026-11-13: confirmed,** 2/s with a burst of 20. |
@@ -74,6 +74,8 @@ Plan choices that are not gaps, for the plan reviewer (each resolves an item on
- **P2-A, two doors answered 200 without a switched app's From:** the environment mint now answers a sender it cannot read as a From not delivered (`*envFromError`: the door cannot tell whether the app is switched), and a re-declare delivers the From whenever the app is switched, not only when the declaration changed, so a retry after a failed delivery delivers.
- **P2-B, the guard held only in its shipped configuration:** the lock test clears its "judged" mark when the app lock is released, so the judgement and the write must share one hold; the lifetime create, the claim-create door and the claim-create finish are each driven and judged; the declare door's app lock is tested; the simulation no longer panics with every environment released, and a wide seed sweep (environment-driven, and run in CI) covers many seeds and steps, Fable's failing seeds among them. P3s: `allocRecordLocked`'s recovery replay judges before it writes; the `*`-parameter rule reads unquoted parameter names only, so a quoted boundary holding `*=` is admitted; and the lock assertion is noted as a detector (a held app lock, not this request's hold).
+6. **Fable's final whole-branch review of `b0aba39b0`: APPROVE, no P1**, so the review stops and its P2s are fixed without another round; Astra's census verdict (M1: the mailer unit unsets `AWS_ACCESS_KEY` and `AWS_SECRET_KEY` too; L1: `statusLoop` has seven sites) is applied. Fixed on the branch: the reap runs from the hourly pass for every account, with or without a plan catalog (P2-5); `email status` reports a switched app's state and pause from its pause block, with no false drift (P2-6); a third concurrent send waits up to 5 s for a sender slot (P2-7); "armed" means AWS accepted the key once (P2-8); the verb answers `403 SUBMISSION_OFF` before reading an unswitched app's body, and bounds the agent's messages across every socket (P2-9); the rollback rule (P2-10, runbook 5c and operator step 12); and the copy fixes (P2-4), with every string of the code now a row of the record and the record checked both ways. P2-1 to P2-3 of that review, in the one-working-channel family, wait on Paul.
+
The copy review (Task 6 P2-6) is still Paul's; the copy record stays a draft.
---
@@ -577,6 +579,7 @@ Per app, in this order: **Alta first** (its team runs are what is blocked), then
- [ ] **Step 1: Inventory** which Oficina apps send mail and which rastrillo path each pins. estilo and fichas are frozen on `github.com/carlosframework/rastrillo v0.23.0` only, and need the module-path migration first: a separate, known item.
- [ ] **Step 2: Per app** (Sonnet, one brief per app): the re-pin, `FromCarlos`, the boot refusal, and `--mail submit` on deploy. Tests: the app boots with `CARLOS_MAIL=submit` and a socket, and with SMTP only, and refuses with neither.
+ **Note (Fable review, 2026-11-14): a seed or a `cmd` one-shot cannot send.** Neither runs with a control socket, and the agent strips `CARLOS_MAIL` from both (`seedVars`, `cmdVars`), so `FromCarlos` there finds no channel for a switched app and refuses at its boot. An app that sends mail from a seed (or calls `FromCarlos` in one) fails that seed once switched: move the send out of the seed, or build the sender lazily and only where it serves.
- [ ] **Step 3: Deploy** each app. It keeps sending over SMTP: no switch is on yet, so no `CARLOS_MAIL` is set.
- [ ] **Step 4: Switch on**: Paul's operator step (below). `carlos email submission on --app <a>` either refuses with the routes or boxes that block it, or switches.
- [ ] **Step 5: Watch** `carlos email status --app <a>` and the event log for 7 days. The reap then happens on its own (Task 6, G4). The rollback is `carlos email submission off --app <a>`.
@@ -588,7 +591,7 @@ Per app, in this order: **Alta first** (its team runs are what is blocked), then
Nothing below is done by the plan's implementers. Each production change needs Paul's scoped approval first (AGENTS.md, 2026-09-15): account, region, resources, permissions, cost, cleanup.
1. **Before Task 6 starts (rulings):** rule on G1-G9. G3 (the From variable), G4 (the reap gate) and G6 (group boxes) change what is built. Confirm or correct G9's rate.
-2. **Before Task 6 starts (facts):** §9 item 3, whether the tenant association backfill has landed. If any Oficina app sender has a `TenantARN`, the control-plane role needs `ses:ListTenantResources` (G8). That policy is outside this repo. §9 item 2: the Oficina boxes' layout (information only).
+2. **Before Task 6 starts (facts), and before any switch-on:** §9 item 3, whether the tenant association backfill has landed. Without `ses:ListTenantResources` on the console's control-plane role, the switch door refuses any app sender with a `TenantARN` ("Can't confirm this app's SES tenant associations"; runbook "Before you start"). If any Oficina app sender has a `TenantARN`, the control-plane role needs `ses:ListTenantResources` (G8). That policy is outside this repo. §9 item 2: the Oficina boxes' layout (information only).
3. **Copy review** for Task 6 step 0.
4. **After the platform merge: release and roll.**
- Cut a platform release and push its tag to the GitHub mirror (AGENTS.md "Deploy reality").
@@ -603,10 +606,18 @@ Nothing below is done by the plan's implementers. Each production change needs P
- `stty -echo; sudo install -m 0640 -o root -g carlos-mailer /dev/stdin /etc/carlos-mailer/keys; stty echo`, paste `<key-id> <secret> <created RFC 3339>`, then Ctrl-D. The `stty -echo` keeps the secret off the terminal and out of any session transcript.
The `.path` unit starts the socket. Check `systemctl is-active carlos-mailer.socket` and, after the first send, `journalctl -u carlos-mailer`. `carlos email status` shows the box as armed.
On a fixed box, also check the IMDS gate allowlists uids and so refuses `carlos-mailer` (`nft list ruleset`, against `scripts/harden-host.sh`).
-7. **New or replaced group boxes** (G6, pending the ruling): until a ruling, each one needs step 6. The `mailer_unarmed@<box>` alert names it.
+7. **New or replaced group boxes** (G6, **ruled by Paul, 2026-11-13: (b)**): each one needs step 6. The `mailer_unarmed@<box>` alert names it, and until it is armed its switched instances answer `503 MAILER_UNAVAILABLE`.
8. **Check before each switch-on** (round 2 P2-B, G10): every route of the app has an instance record. Compare the hosts the boxes serve for the app (`carlos instances --app <a>` on each box that hosts it; the remote form is a known product gap, AGENTS.md "Operate via API and CLI") with the app's instance records (`carlos instances --app <a>` in API mode). A host served with no record is a hand-made route. Give it a record (adoption), or remove it, before switching on. Otherwise it stops at its next start (G10).
-9. **Per app (Task 9 step 4):** `carlos email submission on --app <a>`. Watch for 7 days. The app-level user's reap is automatic.
+9. **Per app (Task 9 step 4):** `carlos email submission on --app <a>`. Watch for 7 days. The app-level user's reap is automatic. **Abort** (`carlos email submission off --app <a>`, then find the cause before switching on again) on any of:
+ - the app reports send failures, or the agent's log shows `403`/`503` answers from the mailer for it;
+ - a `mailer_unarmed` alert for a box hosting it that is not cleared within the hour;
+ - a cap or rate pause of the app sender that the app's own traffic does not explain;
+ - the spawn-time error "build … does not declare --mail submit" for any of its instances;
+ - `carlos email status` showing an instance's environment without a working channel.
+ An `app_user` send in `mail_caller_sends` during the week is not a reason to abort: it means an instance still runs on SMTP and has not restarted, and it only delays the reap.
10. **Rotation** (any time after step 6; runbook): create the second key, arm it on every box in the region (the mailer uses the newer one), confirm every box with `carlos email status` and the journal, then `aws iam delete-access-key` for the old one.
+11. **After every later platform roll** (runbook 5b): `sudo systemctl restart carlos-mailer.service` on each armed box, so the mailer runs the new binary.
+12. **Before rolling the console back past this build** (runbook 5c): switch every app off first. An older console drops the sender's `omitempty` `submission` and `pause` fields when it writes the sender.
---
diff --git a/internal/provision/platform_mail_submission_census_test.go b/internal/provision/platform_mail_submission_census_test.go
index 54803ba0b..51d3de4b4 100644
--- a/internal/provision/platform_mail_submission_census_test.go
+++ b/internal/provision/platform_mail_submission_census_test.go
@@ -139,8 +139,14 @@ func platformMailSubmissionWriteCensusInventory() []censusEntry {
entries = append(entries,
censusEntry{"internal/mail/submission.go", "claimUnserializedSwitchOn", "reference", "id:Put", "9a51854db684923d987663cca49b0b0dafe0c52c57f809e5b1f0cab2c2cd6cc7"},
censusEntry{"internal/mail/submission.go", "claimUnserializedSwitchOff", "reference", "id:Put", "fb3b0cf11f4846eb60aefd09130b0cf0f7e243d79178f1b80446b13d312ae0c8"},
- censusEntry{"internal/mail/sweep.go", "claimUnserializedReapAppUserAfterSubmission", "reference", "id:Put", "1e0ec1ef110c5237e3755004103f4c2698ec68bf726f1345bde2ca64fa466acf"},
+ censusEntry{"internal/mail/sweep.go", "claimUnserializedReapAppUserAfterSubmission", "reference", "id:Put", "7592eb9a0d741809beabab28b118a94c364da6e4fa5a20f9d2b80805a14e0c42"},
censusEntry{"internal/console/alertsignals.go", "engineReads.switchedRecordHosts", "key-site", "key:RecordsPrefix", "9d474c76f8e5326bb99c79b03fd4677adbec77564172a66d1b4a625d2e33e294"},
+ // Fable P3 and P2-8 (2026-11-14): the reap runs again while an
+ // app-level user exists, whatever the reap mark says (the same
+ // Put); and the mailer's arm probe reads one key under the
+ // instance-record pattern, absent by design: a literal, a read,
+ // never a write (key-site, as submissionServeDoors).
+ censusEntry{"internal/mailer/send.go", "const armProbeKey", "key-site", "lit:instances", "ede492afb7ee182babb8c67b06796f803f4df54e99e3b680d368c775328f7354"},
censusEntry{"internal/console/submissiongate.go", "var submissionServeDoors", "key-site", "lit:instances", "072f05e9822cafc73b07ad5863617b9a5db348362b2e747a3ef71b6e665d134b"},
)
return entries
diff --git a/internal/provision/testdata/plan14-root-reads-chain.tsv b/internal/provision/testdata/plan14-root-reads-chain.tsv
index 92c4af4b5..a3a186327 100644
--- a/internal/provision/testdata/plan14-root-reads-chain.tsv
+++ b/internal/provision/testdata/plan14-root-reads-chain.tsv
@@ -217,4 +217,4 @@ plan14-root-reads-g6-pool.tsv 94ccbabaf19c3a449cec248a0c32fcc8593c82d3f7f433c6a4
plan14-root-reads-pdf-host-client-groups.tsv e8beda8fd31db92f742943be631e8d034bbb4880225e69a680d5a0be893807af
plan14-root-reads-log-retention-knobs.tsv e8beda8fd31db92f742943be631e8d034bbb4880225e69a680d5a0be893807af
plan14-root-reads-fleet-record-labels-m1.tsv 5603979dfa1a34a1b30784d1f9252f20b0ed95c114bde54e8b173f9262fe8f46
-plan14-root-reads-platform-mail-submission.tsv 57fa42c9fe9081d760f641f9ae6f65d850a1748ecfba2f64c6d0142eaf71efcc
+plan14-root-reads-platform-mail-submission.tsv 98f09a319faffbf4f0ac2ba6598c66f4dd252cec9f71fb5ec9dc08a636f26617
diff --git a/internal/provision/testdata/plan14-root-reads-platform-mail-submission.tsv b/internal/provision/testdata/plan14-root-reads-platform-mail-submission.tsv
index db8543b32..6a91a17bd 100644
--- a/internal/provision/testdata/plan14-root-reads-platform-mail-submission.tsv
+++ b/internal/provision/testdata/plan14-root-reads-platform-mail-submission.tsv
@@ -1,12 +1,13 @@
# Census overlay platform-mail-submission, written by census-propose (#369). census-ruling-platform-mail-submission, approved on #280 before the merge; the approval card is docs/superpowers/notes/census-proposal-platform-mail-submission.md.
-# 21 body, 6 sites, 16 envelope: each changed unit re-frozen at its existing disposition with its claim appended.
+# 22 body, 6 sites, 16 envelope: each changed unit re-frozen at its existing disposition with its claim appended.
# 17 new dispositions: 0 reads re-frozen at their disposition with the claim, 17 new units frozen accepted-legacy, 0 quiet units retired while they read nothing, 0 other.
@legacy cd11e73e482953f4fc509812b8a95db29d6ff7321d6e8cbb90bc24161432986c cli.go runShip legacy accepted-legacy accepted-legacy;rev3=J4;basis=root-input;rev3=census-ruling-rootfs-apps-1;basis=rootfs Plan 1 Task 9: takes --rootfs, --processes, --hibernate, --jit and --check and hands a rootfs ship to runShipRootfs (ship_rootfs.go) before the binary path; the --notes-file ReadFile moved into shipNoteText (its own row, the same read of the file the person named) and the direct-mode version mint into mintDirectVersion; one read site fewer, none added; Task 12: the --hibernate flag help is RFS-1-C32's new text, the same reads;rev3=census-ruling-edge-asset-cache-1;basis=takes --assets (repeatable), checks the folders with checkShipAssets (release.ValidAssetPaths; refused on a static site) before the mode split, carries them into the API meta (sess.shipAssets) and the direct-mode manifest (shipAssetsBlock), and passes them to runShipRootfs (rootfsShipOpts.assets), which runs the same check and carries them the same two ways; after a direct-mode ship has stored a release declaring folders, directShipAssetGens runs the console ship door's backfill (provision.MintMissingAssetGens: lists the app's record keys and gives each record without an asset generation one, a CAS write in the deployment bucket as the person running the CLI) and fails naming any record it could not mint; read sites unchanged (2), none added;rev3=census-ruling-rootfs-apps-4;basis=adds the repeatable --env flag and refuses it before anything else unless --check is given (shipEnvRefusal, parseShipCheckEnv); the parsed values go into rootfsShipOpts.checkEnv. --env values reach the check's local container runtime as -e argv only, never root, never a box. No read added; read sites unchanged (2).;rev3=census-ruling-stateless-replicas-1;basis=Carry --stateless into binary/API and rootfs ship options; same two read sites, no new read.;rev3=census-ruling-platform-mail-submission;basis=Task 6: a --mail flag (only "submit" accepted, refused with one line otherwise, and refused with --rootfs), set on the manifest in direct-bucket mode and sent to the console in API mode, where a console that does not echo it is refused (ship_mail.go, apimode.go), as --stateless is. A person's ship command; no root read, no box state. file:ReadFile@8054,file:ReadFile@8278 342325f3f6dcd03f09a75513df923a3b669eaef37e8c86ba699f037e21b6ee18
@legacy 12110bd4e36dfb84a8352ad3b2ae1f8de1fe5f118f805606a148de17705e112e infra/modules/region-host/outputs.tf external legacy accepted-legacy accepted-legacy;rev3=J4;basis=root-input;rev3=census-ruling-region-ha-p3b;basis=Keep fixed outputs through indexed resources, return null for group instance/EIP, and expose group, pinned template, ingress and boot-parameter names. Operator Terraform outputs only; no new box read.;rev3=census-ruling-region-ha-g2-fixes;basis=Expose the module alert topic ARN, null without an alerts topic; no new box runtime read.;rev3=census-ruling-region-ha-g3-fixes;basis=Return the selected existing or module-created alert topic ARN, null when neither input is set. Terraform output only; no new root runtime read.;rev3=census-ruling-managed-fleets-2b1;basis=managed fleets 2b-1 Task 5: three outputs, managed_fleet_user_boundary_arn, managed_fleet_user_path and managed_fleet_bucket_prefix, each null unless managed_fleets_enabled; Terraform outputs for the operator only; no box runtime read is added;rev3=census-ruling-w6-ingress-drain;basis=new output ingress_target_groups: the ARNs joined with commas in fixed mode when set, null otherwise and in group mode; the operator copies it into the box's host.env (CARLOS_INGRESS_TARGET_GROUPS) by hand. Output only; no read added.;rev3=census-ruling-platform-mail-submission;basis=Task 8: output "mailer_user_name", the user's name or null. Read-only. file:external@0 fc7a4e1f10e52775047a9b0cedb636a00641e8f6831970baefea419871be9868
@legacy 4ef72ca2ef3fd96a836ca96e6e8ed2a3cd8c730d65010fcf2d46cf7f810ac42a infra/modules/region-host/variables.tf external legacy accepted-legacy accepted-legacy;rev3=census-ruling-console-invite-delivery;basis=tofu on an operator's machine with the operator's AWS credentials (no box unit; no binary embeds the file): main's variables with console_mail_from (validated as one lowercase address) and console_mail_region, both empty by default; no read is added and nothing on a box reads the file;rev3=census-ruling-hunt-account-root-hardening;basis=adds deny_release_key_reads (bool, default true); no read is added and nothing on a box reads the file;rev3=census-ruling-region-ha-p3b;basis=Add default-fixed mode and validated group count, zones, pinned image/release/template, ingress, configuration key and transaction-open refusal. Operator-supplied Terraform values select root boot inputs; no direct box runtime read and no group activation by default.;rev3=census-ruling-region-ha-g2-fixes;basis=Add an empty-default set of additional alert topic ARNs, validating concrete SNS topic syntax and excluding wildcards/subscriptions; operator Terraform input, no box runtime read.;rev3=census-ruling-region-ha-g3-fixes;basis=Add optional alerts_topic_arn with concrete same-region SNS ARN validation and mutual exclusion with alerts_email. The caller owns the existing topic policy and subscriptions; no runtime sink is configured and no new root read is added.;rev3=census-ruling-managed-fleets-2b1;basis=managed fleets 2b-1 Task 5: five variables, managed_fleets_enabled (bool, default false, refused unless mode is fixed), managed_fleets_deployment, managed_fleets_regions (concrete ami/subnet/sg IDs, arm64 types, no ID in two regions), managed_fleet_bucket_prefix (1-24 chars, no reserved prefix, must not cover the deployment, data or staging buckets, disjoint from store_bucket_prefix) and managed_fleet_user_path (literal IAM path, disjoint from store_user_path); store_bucket_prefix and store_user_path gain a validation refusing *, ? or ${ only when managed fleets and object storage are both on; operator Terraform input only; no box runtime read and nothing on a box reads the file;rev3=census-ruling-fixedbox-health-alarms;basis=Add optional health_alerts_topic_arn (concrete same-region SNS ARN validation, empty default); enable_auto_recovery description covers both status alarms. Operator Terraform input; no box runtime read.;rev3=census-ruling-w6-ingress-drain;basis=new variable ingress_target_group_arns (list(string), default [], non-nullable) validated as distinct ELB target group ARNs (arn:aws(-x)*:elasticloadbalancing:<region>:<12 digits>:targetgroup/<name>/<16 hex>); drives the IAM policy and output above. No read added.;rev3=census-ruling-stats-prune-400;basis=new variable enable_analytics_version_prune (bool, default false) driving the policy above; operator Terraform input; no box runtime read;rev3=census-ruling-platform-mail-submission;basis=Task 8: variable "mailer", an object {ses_region, ses_account_id, deployment_bucket_region, optional deployment_bucket_kms_key_arn} defaulting to null, which creates nothing; validated (AWS region shapes, 12-digit account, KMS ARN or empty). file:external@0 4e3076d5835fcd03f51edcd5f6847371c2f2059598b4bf7841cba2aead5b3754
+@legacy 901d155a108cd677bde6d864798e22b56eed5a42eafa8595ccc62c51f453fecc internal/activator/cmdunit.go ExecBackend.cmdVars legacy accepted-legacy accepted-legacy;rev3=census-ruling-carlos-run;basis=the agent (/opt/carlos/carlos agent, carlos-edge.service, user carlos): composes the command's environment over the serving generation's launch snapshot; the host comes from the row, never from a tenant file;rev3=census-ruling-stateless-replicas-1;basis=Task 3a: Use the verified generation/launch mode to remove CARLOS_DB after environment merges and omit the binary --db argument where applicable. Existing runtime, layout, secrets and exec gates remain; route reads are mode projection only.;rev3=census-ruling-platform-mail-submission;basis=Fable P3 (2026-11-14): a cmd one-shot's environment also strips CARLOS_MAIL, as seedVars does: a one-shot has no control socket, so it cannot submit mail. Only narrows what a run is given; no read added. Agent, not root. registry:Host@356,whole:Route@462 75f3a85e8bdbb5a27b22eeb094135628e315d4c4c80482040b836ceb44955ad9
@legacy 2d0d5c7d06f3d3299a7b17609928866ebb192d07468a1876e0ad9df56571ace8 internal/host/agent.go fastTick legacy accepted-legacy accepted-legacy;rev3=J1;basis=root-route;rev3=PROPOSED-s3-change-index;identity=the agent (/opt/carlos/carlos agent, carlos-edge.service, user carlos);basis=observes the change index before any pass (observeIndex), runs the backstop's requested full pass and a scoped pass for moved app scopes (indexTick), and arms the canary pointer gate on the sweep (canaryPointerGate) only on a tick whose own index observation succeeded; read site unchanged, offset moved;rev3=census-ruling-stateless-replicas-1;basis=Call coordinator Tick on the existing tick before convergence; client renews held terms only at the pinned interval. Existing registry read unchanged. Final review I3: signal the owned renewal worker instead of waiting for its sequential console HTTP calls. Existing convergence and record read unchanged.;rev3=census-ruling-region-ha-p3a;basis=Run the optional desired-role reader on the existing tick after observing the armed change index; no new root path or timer, nil reader is unchanged.;rev3=census-ruling-stateless-replicas-2;basis=Slice 3b: signals the owned replica worker on the existing tick; coalesced asynchronous execution, no timer or bucket scan added. merge of origin/main 7920cccf: Retain main box-role reader pass on the existing tick alongside the replica worker signal; merge-only body change, unchanged read sites.;rev3=census-ruling-restart-new-box-gap;basis=calls the optional restartGain hook (restartGainSeed) once per existing tick before the serial read; no new root path, timer or read kind; nil hook is unchanged;rev3=census-ruling-agent-start-demo-3;basis=Refresh moved notices through the shared watch before normal convergence; no new per-box poll. Census read-site delta: unchanged (1).;rev3=census-ruling-stateless-replicas-4-task1;basis=Signals the owned replica swap worker (armedReplicaDeploy.tick) beside the placement worker on the existing tick; coalesced background pass, no timer, no bucket read. Its transitions go through the console's authenticated /deploy.;rev3=census-ruling-platform-mail-submission;basis=Task 4: on a serial move, after the schedule leg, starts the armed mail switch cache's Refresh on its own goroutine (each read bounded at 2 s, overlapping refreshes skipped). It re-reads the app sender records already cached, through the agent's deploy store. Agent, not root; the tick waits on nothing new. registry:Host@5822 a1cd273f24047c63670f8c32c000a84f1a3861d058da38c5318551929f312390
@legacy 562d26b51dcbce93d68fabfe933e074c2b2933fcded74156fd88f559407862da internal/host/agent.go provisionTickConfig legacy accepted-legacy accepted-legacy;rev3=J4;basis=root-input;rev3=census-ruling-ha-p1a-433;basis=the agent (carlos-edge.service, user carlos) and the edges file loop's eligibility: the same CARLOS_POOLS read, now parsed by provision.ParseBoxPools (internal/provision, envelope re-pinned), the one parser boxPools also uses. "@shared" (provision.SharedPoolToken, never a valid pool name) is the shared "" pool; other tokens are literal as before; empty elements and repeats dropped. No read added.;rev3=census-ruling-managed-fleets-1b;basis=managed fleets 1b (Task 4, rule 2): sets ReconcileConfig.FleetBox to the box's own fleet label from resolveFleetIdentity(getenv), only when the identity resolves and region == PlacementTarget(identity.Fleet); otherwise it stays "" (the box admits only unlabelled records). The same environment the fleet loops already read; read sites unchanged (2). Agent config, not root.;rev3=census-ruling-platform-mail-submission;basis=Task 5: its region, pools and fleet label now come from BoxScopeFromEnv, which is the same three reads moved out unchanged (CARLOS_REGION trimmed, provision.ParseBoxPools(CARLOS_POOLS), and resolveFleetIdentity's label only when its fleet is the one the region places the box on), so the box-local mailer resolves "on this box" by the agent's rule. The ReconcileConfig it returns is field for field what it was. Agent, not root. data-literal@173,data-literal@214 cabe3cb9662118eb82ddbc77dbbdb80b6718494caea097c8ffb894ccc4903fe3
-@legacy cbc74621890e2fc074cde212107d0aa7ec6348b364881fc201d5352ebdd30524 internal/host/agent.go statusLoop legacy accepted-legacy accepted-legacy;rev3=census-ruling-self-serve-moves-1;basis=the agent (/opt/carlos/carlos agent, carlos-edge.service, user carlos): the status tick's context carries the box's lifetime judge; read sites unchanged, offsets moved;rev3=census-ruling-rootfs-apps-2;basis=main's body as of the merge of origin/main 953b9fda (its later changes, regional box names and self-serve moves plan 1 among them, under main's own census rulings), where the tick fills rootfs_ready and rootfs_blocked from armedRootfs.Load().probe, which each tick runs NestedOK's checks and asks the control socket's GET /ready/rootfs (never the store); the same four direct sites;rev3=census-ruling-instance-egress-sizes-328-329;basis=#328 plan 2 Task 11 and #329 plan 3 Task 7: takes root's GET /egress reader and fills p.Egress = egressStatusProbe(egressStatus, routes, provision.PolicyReadStates()) and p.SizeCommittedMiB = sizeCommittedMiB(armedSizeSource.Load(), routes); the two added whole:Route sites are the tick's own registry list handed to those two units (decision rows), which read root's control socket and the activator's memory; no store request added; the four existing sites unchanged, offsets moved.;rev3=census-ruling-fleet-alerts-1;basis=the agent (carlos-edge.service, user carlos): the status tick passes os.Geteuid() to alertDeliveryProbe, which fills AlertDelivery.EngineBeat/EngineBeatWhy from engineBeatArmed (the env value and the euid only, no file access, root refused before the path is looked at), and fills Probes.DiskFullETAHours from diskETAProbe(&processDiskTrend, now), a Theil-Sen fit over the metrics loop's in-memory ring of disk readings; the same six sites, no read added, no store request added;rev3=census-ruling-edge-held-streams;basis=the agent (/opt/carlos/carlos agent, carlos-edge.service, user carlos): the status tick's Probes gain HeldStreams: heldStreamsState(), which calls the edge's in-memory counters function (nil until the edge is ready). No file, bucket or registry access added.;rev3=census-ruling-stateless-replicas-3;basis=Fix round 1 Q20: read the detached in-memory replica snapshot source into Probes.ReplicaCopies on the existing five-minute tick. Existing six direct read sites unchanged. No additional bucket request, changed cadence or app lifecycle action.;rev3=census-ruling-agent-start-demo-3;basis=Report moved capability only when the serving edge reports readiness; report claim-seed support only with CARLOS_DEMO_CLAIM=1. Reads the explicit capability flag from the process environment; no new filesystem or registry read.;rev3=census-ruling-stateless-replicas-4-task5;basis=Task 5 fix round 1 (#511 R16 amendment): the status tick also fills Probes.ApplyFinished from systemApplyFinished(release.OptDir()), an Lstat of root's apply journal <opt>/system/router/journal.json in the root-owned, world-readable state directory: finished only when the journal is absent, any other answer unknown and so unfinished. Round 0: Probes.PrevRelease from prevReleaseOf (carlos.prev and carlos.prev.version, the files withMovesFields already reads). Reported in the private BoxMetrics block; no bucket request or cadence change.;rev3=census-ruling-offline-move-stage-refusals-339;basis=#339: the agent (carlos-edge.service, user carlos): the status tick fills p.OfflineMove = offlineMoveFactsProbe(routes); the added whole:Route site is the tick's own registry list handed to that unit, which under a non-root euid lists the names of root's <opt>/live and nothing else; no store request added.;rev3=census-ruling-platform-mail-submission;basis=Task 3 (plan gap G6 (b)): the status tick also fills Probes.MailerArmed from mailerArmed(mailwire.MailerSocket, 2s): a stat of /run/carlos-mailer/mailer.sock and, only when it is a socket, GET /v1/health on it. The agent (carlos-edge.service, user carlos), not root; reported in the private BoxMetrics block only. The same six sites; no store request, no read of /etc/carlos-mailer (which uid carlos cannot traverse). whole:Route@10554,whole:Route@12628,whole:Route@12909,whole:Route@13267,whole:Route@6583,whole:Route@6610,whole:Route@7918 352bd5962a711a29f0f0f2f0d5e4d0a9a58f41ebf049e4f37ff41c31a4ea4eae
+@legacy 8a3138bade129a8c842dda4b12dc687af177d73ddfd0a9b5cf071432455f9550 internal/host/agent.go statusLoop legacy accepted-legacy accepted-legacy;rev3=census-ruling-self-serve-moves-1;basis=the agent (/opt/carlos/carlos agent, carlos-edge.service, user carlos): the status tick's context carries the box's lifetime judge; read sites unchanged, offsets moved;rev3=census-ruling-rootfs-apps-2;basis=main's body as of the merge of origin/main 953b9fda (its later changes, regional box names and self-serve moves plan 1 among them, under main's own census rulings), where the tick fills rootfs_ready and rootfs_blocked from armedRootfs.Load().probe, which each tick runs NestedOK's checks and asks the control socket's GET /ready/rootfs (never the store); the same four direct sites;rev3=census-ruling-instance-egress-sizes-328-329;basis=#328 plan 2 Task 11 and #329 plan 3 Task 7: takes root's GET /egress reader and fills p.Egress = egressStatusProbe(egressStatus, routes, provision.PolicyReadStates()) and p.SizeCommittedMiB = sizeCommittedMiB(armedSizeSource.Load(), routes); the two added whole:Route sites are the tick's own registry list handed to those two units (decision rows), which read root's control socket and the activator's memory; no store request added; the four existing sites unchanged, offsets moved.;rev3=census-ruling-fleet-alerts-1;basis=the agent (carlos-edge.service, user carlos): the status tick passes os.Geteuid() to alertDeliveryProbe, which fills AlertDelivery.EngineBeat/EngineBeatWhy from engineBeatArmed (the env value and the euid only, no file access, root refused before the path is looked at), and fills Probes.DiskFullETAHours from diskETAProbe(&processDiskTrend, now), a Theil-Sen fit over the metrics loop's in-memory ring of disk readings; the same six sites, no read added, no store request added;rev3=census-ruling-edge-held-streams;basis=the agent (/opt/carlos/carlos agent, carlos-edge.service, user carlos): the status tick's Probes gain HeldStreams: heldStreamsState(), which calls the edge's in-memory counters function (nil until the edge is ready). No file, bucket or registry access added.;rev3=census-ruling-stateless-replicas-3;basis=Fix round 1 Q20: read the detached in-memory replica snapshot source into Probes.ReplicaCopies on the existing five-minute tick. Existing six direct read sites unchanged. No additional bucket request, changed cadence or app lifecycle action.;rev3=census-ruling-agent-start-demo-3;basis=Report moved capability only when the serving edge reports readiness; report claim-seed support only with CARLOS_DEMO_CLAIM=1. Reads the explicit capability flag from the process environment; no new filesystem or registry read.;rev3=census-ruling-stateless-replicas-4-task5;basis=Task 5 fix round 1 (#511 R16 amendment): the status tick also fills Probes.ApplyFinished from systemApplyFinished(release.OptDir()), an Lstat of root's apply journal <opt>/system/router/journal.json in the root-owned, world-readable state directory: finished only when the journal is absent, any other answer unknown and so unfinished. Round 0: Probes.PrevRelease from prevReleaseOf (carlos.prev and carlos.prev.version, the files withMovesFields already reads). Reported in the private BoxMetrics block; no bucket request or cadence change.;rev3=census-ruling-offline-move-stage-refusals-339;basis=#339: the agent (carlos-edge.service, user carlos): the status tick fills p.OfflineMove = offlineMoveFactsProbe(routes); the added whole:Route site is the tick's own registry list handed to that unit, which under a non-root euid lists the names of root's <opt>/live and nothing else; no store request added.;rev3=census-ruling-platform-mail-submission;basis=Task 3 (plan gap G6 (b)): the status tick also fills Probes.MailerArmed from mailerArmed(mailwire.MailerSocket, 2s): a stat of /run/carlos-mailer/mailer.sock and, only when it is a socket, GET /v1/health on it. The agent (carlos-edge.service, user carlos), not root; reported in the private BoxMetrics block only. The same seven sites; no store request, no read of /etc/carlos-mailer (which uid carlos cannot traverse). whole:Route@10554,whole:Route@12628,whole:Route@12909,whole:Route@13267,whole:Route@6583,whole:Route@6610,whole:Route@7918 352bd5962a711a29f0f0f2f0d5e4d0a9a58f41ebf049e4f37ff41c31a4ea4eae
@legacy 722920e1d095fe935962342d131ef5e8d5c97481b52b7ddc38dc214bf84ee9a5 internal/host/bootstrap.go bootstrapWithGroup legacy accepted-legacy accepted-legacy;rev3=census-ruling-region-ha-p3b;basis=Move bootstrapWith body here, retaining host.env, embedded unit reads and tmpfiles execution. Group live caller holds root mutation guard; skip automatic update/recovery units, preserve Restart=no/nftables drop-in and masks, and write separate root-owned /run/carlos-group-maintenance tmpfiles rule outside service ownership walk. No agent receipt read.;rev3=census-ruling-gvisor-demos;basis=Create the rootfs parent at 0700 and runtime root at 0755. Existing host.env/unit reads unchanged; workload templates remain unarmed.;rev3=census-ruling-platform-mail-submission;basis=Task 3: the sysusers.d/carlos.conf it writes is now the constant sysusersConf, which adds "u carlos-mailer - \"CARLOS mailer\" - /usr/sbin/nologin" ahead of the existing "g carlos-sockets -" line, so the tmpfiles line naming group carlos-mailer resolves on a box whose confs arrive by a staged-tree refresh. Constant text, no input; no read added. file:Command@12045,file:ReadFile@564,file:ReadFile@7111 62fa76ad0fa812a0effc7c6add43ddcf54313450c13f20fbb2fee9d004488588
@legacy aea72efedb3cc995ae9c791962e3e80f7dfe0b54d87da8c3ca13616baf7a433b internal/host/bootstrap.go privilegedPlan legacy accepted-legacy accepted-legacy;rev3=J4;basis=root-input;rev3=census-ruling-platform-mail-submission;basis=Task 3: one more constant argv, useradd --system --user-group --no-create-home --shell /usr/sbin/nologin carlos-mailer, right after carlos's, behind runPrivileged's existing guard (user.Lookup of the argv's own last word). No input; no read added. data-literal@382 4f353dc38a329ff88fdec4bc2611c44b7ac483eee308b73f58100abc539707cc
@legacy 72a9a01566413d03e47904622675de11f9728a7412ccd1c66164f6b269500437 internal/host/demo_units/demo.conf external legacy accepted-legacy accepted-legacy;rev3=census-ruling-agent-start-demo-1;basis=Retains read-only /run and /var tmpfs overlays and all network/size restrictions. Resets InaccessiblePaths and restates /etc/carlos -/run/carlos-control so the hidden control directory need not exist during namespace setup; /etc/carlos remains required. No new source or bind.;rev3=census-ruling-platform-mail-submission;basis=Task 3: the restated InaccessiblePaths= line after the reset gains -/run/carlos-mailer -/etc/carlos-mailer, so a demo box's drop-in does not drop the mailer entries carlos-instance@ and carlos-instance-gen@ now carry. Optional entries; only hides more; no source or bind added. file:external@0 a9e9b766b8dc528c67e128622901f5e491c8abf247681c4e0a4479fbea5d25b9
@@ -23,12 +24,12 @@
@legacy 683a26c2185a385d210ce4b376f13740422e0e405a09e402953a0457ca608508 infra/modules/region-host/mailer.tf external legacy accepted-legacy accepted-legacy;rev3=census-ruling-platform-mail-submission;basis=Task 8, new: with var.mailer set (default null: nothing), aws_iam_user.mailer carlos-mailer-<region> at path /carlos-mailer/ (precondition: ses_account_id is the module's own account) and aws_iam_user_policy.mailer with ses:SendRawEmail on identity/*, configuration-set/carlos-* and tenant/carlos-*/* in ses_region (the tenant per Task 8 review P2-1, as the console's own policy grants its tenant), and s3:GetObject on apps/*/*/email/senders/*, apps/*/*/instances/* and accounts/*/email/domains/* (plus kms:Decrypt via S3 only when a bucket KMS key is given). No s3:ListBucket, no write, no IAM action, no access key resource (the key never enters state). The host role gains nothing. In group mode two String region parameters, CARLOS_MAIL_REGION and CARLOS_DEPLOYMENT_REGION, under the region's existing /carlos/<deployment>/<region>/ path, which host-env write --group already reads and validates against hostenv's allowlist. References no sibling script; nothing a box's root runs or reads beyond those two plain values. file:external@0 a48c782bf4f63f5121c6ccae7d19793f0af4c9f9856127319f6bb9014357890f
@legacy 1dfce6c598f867f9f8e3251758ab91e9a1d16656d9831806b5fab5b8c5421952 infra/modules/region-host/tests/mailer.tftest.hcl external legacy accepted-legacy accepted-legacy;rev3=census-ruling-platform-mail-submission;basis=Task 8, new: plan-only runs under mock_provider: off by default; the user's name and path; the policy's two statements exactly; no ListBucket, Put, delete, SendEmail, IAM or wildcard action; KMS adds decrypt through S3 only; another account refused; a bad region refused; the host role gains no SES. Test-only. file:external@0 d8f1e5acb446a2e33848958b3ea036ab81c1f17565ab8df5409883b0afb39164
@legacy e22f1e9844d61fe949ab40748b17135bde43efa378e310b484c471ffbce7eed9 infra/modules/region-host/tests/mailer_group.tftest.hcl external legacy accepted-legacy accepted-legacy;rev3=census-ruling-platform-mail-submission;basis=Task 8, new: plan-only runs under mock_provider with group.tftest.hcl's fixtures (plus an AMI override): the two region parameters' names and values with mailer set, none without. Test-only. file:external@0 c36b70fc72d0b317db438c66a7e669a49a92ddce904ae8307f3503031c53f73f
-@legacy 5cd628b73d71ab551cb5451e3b7ca0cfa184638efa4b210e2dbef51e32c30b91 internal/activator/backend_exec.go ExecBackend.controlMount legacy accepted-legacy accepted-legacy;rev3=census-ruling-platform-mail-submission;basis=Task 4, new: the one composer of a control socket's verbs, for both bind sites. Mounts the schedule verbs and GET /updates exactly as the two inline copies did (same conditions, same host, token reader and write fence), and POST /v1/mail (mailsubmit.Mount) under its own condition, b.Mail != nil. Reads rt.Host and passes the route to Mount; returns nil when nothing is mounted. The agent (carlos-edge.service, user carlos), not root. registry:Host@292,registry:Host@347,registry:Host@426,whole:Route@515 827650c1147231c19b6da7e41f3fc97fa4c28e3eda76961dfa788bc9c25f536e
+@legacy 9c70d586be7aafa1e5c00e564bfac7347f702aed86c67a2072e95d58545d5e00 internal/activator/backend_exec.go ExecBackend.controlMount legacy accepted-legacy accepted-legacy;rev3=census-ruling-platform-mail-submission;basis=Task 4, new: the one composer of a control socket's verbs, for both bind sites. Mounts the schedule verbs and GET /updates exactly as the two inline copies did (same conditions, same host, token reader and write fence), and POST /v1/mail (mailsubmit.Mount) under its own condition, b.Mail != nil. Reads rt.Host and passes the route to Mount; returns nil when nothing is mounted. The agent (carlos-edge.service, user carlos), not root. Fable P2-9: passes b.MailSwitch to mailsubmit.Mount. No read added. registry:Host@292,registry:Host@347,registry:Host@426,whole:Route@515 df735c417720309504a5623549c6f02ec8050bcbdcb8b42d05ef31380710ca93
@legacy bce32b49d764738f9b80e81a4b6473b446149bb1e62062886297d1431cc4cc4e internal/activator/backend_exec.go ExecBackend.mailSubmits legacy accepted-legacy accepted-legacy;rev3=census-ruling-platform-mail-submission;basis=Task 4, new: the CARLOS_MAIL rule. Reads rt.App, rt.Host, rt.Provisioned and RouteAccount(rt) from the agent's own registry row, and asks b.MailSwitch (the agent's cache of the console-written app sender record, internal/host/mailswitch.go: one bounded Get of apps/<acct>/<app>/email/senders/app.json through the agent's deploy store). Logs once per host at error level for an unprovisioned route of a switched app. Agent, not root; no file read. registry:App@213,registry:App@526,registry:Host@317,registry:Host@511,registry:Provisioned@246,whole:Route@185 cfd7494b38dc64c2710233dbc2da850eb7b89fc9aecfa648cd7affd5e9a354d0
@legacy 3b93bc668acb347c8b3a81163a8718993c852cb5675cc33c30a431a42d22b331 internal/activator/mailbuild.go ExecBackend.warnUndeclaredMailBuild legacy accepted-legacy accepted-legacy;rev3=census-ruling-platform-mail-submission;basis=Task 6, new: design decision 10's loud log, never a refusal (a refused wake would turn a mail gap into a site outage). Asks the agent's switch cache (MailSwitch) and reads the staged manifest of the version being spawned through ManifestOf (release.ReadStagedManifest, the read TierOf already makes); logs at error level and emits one instance event per (host, version). Agent, not root; reads only what the spawn already reads. registry:App@1201,registry:App@219,registry:App@848,registry:Host@1177,registry:Host@249,registry:Host@819,whole:Route@1228,whole:Route@191,whole:Route@368 e36bed0c8ebdd741227e4805972b569f78497105874c75832dbcb0ccf17956f3
@legacy d6700cb69f36e6e7cb8fdf4f4b747269ba9bf6545143e4dd943acedc018bc4b1 internal/host/mailerreport.go mailerArmed legacy accepted-legacy accepted-legacy;rev3=census-ruling-platform-mail-submission;basis=Task 3, new: the agent's MailerArmed probe. Stats the constant socket path and dials it for GET /v1/health with a 2 s timeout; true only on a 200. Runs in the agent as carlos, never as root; the path is a constant, in a root-owned 0750 root:carlos directory nothing a tenant or an app can write. Answers a bool into the private status block. file:Stat@72 6fd83d5c27429d06864d02a141f7036c2f3e1e8e89366ad6d2a232d417420052
@legacy 85d678c6a608ff70b7a60141d0efde911544f4b7aa9a7d9508f0e13cf2b7e724 internal/host/units/carlos-mailer-arm.path external legacy accepted-legacy accepted-legacy;rev3=census-ruling-platform-mail-submission;basis=Task 3, new: [Path] PathExists=/etc/carlos-mailer/keys, Unit=carlos-mailer.socket, WantedBy=multi-user.target; enabled and armed by bootstrap like every .path. PID 1 watches a path in a root-owned 0750 root:carlos-mailer directory only root (the operator) writes; it starts a socket unit and reads nothing. file:external@0 6b28c6282ee930560f859f20c752c65f0e550412b9c6ffb1fc10c292a3941a2a
-@legacy 32524609e5d66b8b235d4575ac82e8e30b33b63e7e7d65bc181a95eb7572a535 internal/host/units/carlos-mailer.service external legacy accepted-legacy accepted-legacy;rev3=census-ruling-platform-mail-submission;basis=Task 3, new: runs /opt/carlos/carlos mailer serve as the static user carlos-mailer (never root), socket-activated, ConditionPathExists=/etc/carlos-mailer/keys, EnvironmentFile=-/etc/carlos/host.env (read by PID 1, as every carlos service's) with UnsetEnvironment= of every credential a host.env may carry (CARLOS_SECRETS_KEY, CARLOS_RELEASE_KEY, the tunnel, service, sidecar and DNS tokens, the alert webhook, CARLOS_ADMIN_TOKEN, CARLOS_INSTANCE_KEY, AWS keys and profiles; review round 1 Task 3 P3), AWS_EC2_METADATA_DISABLED=true, IPAddressDeny=169.254.169.254/32 fd00:ec2::254/128, StateDirectory=carlos-mailer 0700, and the relay's hardening block with no ReadWritePaths; Environment=GOMEMLIMIT=288MiB with MemoryHigh=320M and MemoryMax=384M for four 10 MiB sends (review round 1, Task 5 P3). No root process reads anything new; the mailer reads its own key file and state. file:external@0 4c0f0138683659416f50fbcfdbf18df6592ae03531538e2d98f9f2392659c7cb
+@legacy 4ad5b393a6c6cc39f01cf25506e98100e3075bd2f06594d763978b8605d8e48d internal/host/units/carlos-mailer.service external legacy accepted-legacy accepted-legacy;rev3=census-ruling-platform-mail-submission;basis=Task 3, new: runs /opt/carlos/carlos mailer serve as the static user carlos-mailer (never root), socket-activated, ConditionPathExists=/etc/carlos-mailer/keys, EnvironmentFile=-/etc/carlos/host.env (read by PID 1, as every carlos service's) with UnsetEnvironment= of every credential a host.env may carry (CARLOS_SECRETS_KEY, CARLOS_RELEASE_KEY, the tunnel, service, sidecar and DNS tokens, the alert webhook, CARLOS_ADMIN_TOKEN, CARLOS_INSTANCE_KEY, AWS keys and profiles; review round 1 Task 3 P3), AWS_EC2_METADATA_DISABLED=true, IPAddressDeny=169.254.169.254/32 fd00:ec2::254/128, StateDirectory=carlos-mailer 0700, and the relay's hardening block with no ReadWritePaths; Environment=GOMEMLIMIT=288MiB with MemoryHigh=320M and MemoryMax=384M for four 10 MiB sends (review round 1, Task 5 P3). No root process reads anything new; the mailer reads its own key file and state. file:external@0 3b9c4fa4c4487653863e3140d4007a8c873b031649f9e53b318b4802305c085e
@legacy 486f70ac08ac5f675d91dc3b7bddf949c908db227e4596af5706df846c4fb32f internal/host/units/carlos-mailer.socket external legacy accepted-legacy accepted-legacy;rev3=census-ruling-platform-mail-submission;basis=Task 3, new: ConditionPathExists=/etc/carlos-mailer/keys, ListenStream=/run/carlos-mailer/mailer.sock, SocketUser=carlos, SocketGroup=carlos, SocketMode=0600, Accept=no; not enabled, started only by the arming path. PID 1 binds a socket in a root-owned directory, as carlos-instance-control.socket does in /run/carlos-control. No read added. file:external@0 275aae364c39e89bdf3d76d7e66aea9cf65b398ac0c16c087db353cfd5140c34
@legacy 6124a227150c2055499a081f370c0d3211decfc51a16ff34a0449493b2a94cb3 internal/mailer/counter.go Counter.loadLocked legacy accepted-legacy accepted-legacy;rev3=census-ruling-platform-mail-submission;basis=Task 5, new: reads the day's counts file from the mailer's own state directory; a body that does not decode is renamed aside, logged loudly, and the day restarts at zero (the per-box bound §4.1 (a) accepts). carlos-mailer only. file:ReadFile@142 a317a61e58c996133e1ae96045932c927052cb5f44720fb90193ae45abbe2d1b
@legacy 66171fc9229872bbf17d3f26e75389dbacb7171bbd7ff08f5c820b60140e2ebf internal/mailer/counter.go Counter.writeLocked legacy accepted-legacy accepted-legacy;rev3=census-ruling-platform-mail-submission;basis=Task 5, new: writes the day's counts durably (temp file in the same directory, fsync, rename, directory fsync) before a send. carlos-mailer only, in its own state directory. file:CreateTemp@118,file:Open@489 40cb38a8252e6c90bd21efdfafc7bbcb9b66b04a10bf9c2154f5796e1bff4820
@@ -36,7 +37,7 @@
@legacy 09ddb6ec28ddc32798b2afd4909d661e9da73e8a6cf48c6b8a73f9fa00bb0cba internal/mailer/keys.go KeyFile.Changed legacy accepted-legacy accepted-legacy;rev3=census-ruling-platform-mail-submission;basis=Task 5, new: a stat of the same constant key path, compared with the loaded file's mtime, size and inode, so a rotation reloads with no restart. carlos-mailer only. file:Stat@47 1e4714c15a0cde077167358d786eaa3b33d6a9f3330a5d282dbba59beb1a3299
@legacy c577b1c36d95d7616e46d796828771d5e9a7d2b7229d0c6b3353c3ec4c313bf7 internal/mailer/keys.go loadKeys legacy accepted-legacy accepted-legacy;rev3=census-ruling-platform-mail-submission;basis=Task 5, new: reads /etc/carlos-mailer/keys (a constant path) as carlos-mailer: refuses anything but a regular 0640 file owned by root and group carlos-mailer, more than two keys, or a malformed line; errors never carry a secret. Root never reads it. The file is written by the operator by hand, in a 0750 root:carlos-mailer directory uid carlos cannot traverse. file:Open@68,file:ReadFrom@488,file:Stat@154 c86150ed82395d1051892825ea4893a289e2eda699372974c4373845794d707d
@legacy 92d90fe8f4ae11810f6e85c8df7ceb2a4024c8da10e42c8788ee154f5b8a60ce internal/mailsubmit/forward.go SocketForwarder.Send legacy accepted-legacy accepted-legacy;rev3=census-ruling-platform-mail-submission;basis=Task 4, new: the agent's client to the mailer: one HTTP POST of /v1/send over a fresh dial of the constant /run/carlos-mailer/mailer.sock, 60 s timeout, answer read to at most 64 KiB and decoded. Runs in the agent, as carlos. The socket's directory is root's; the mailer at the other end is a separate uid. file:ReadAll@885 b1c14436f42f60c4157ad0dffb1b998931a58b3a2ebf545578ff6d2e243dcd58
-@legacy 22a67d4320a618752b7f0430b8b8e51c0e4e0bc2b5f8a08d5bf22ed2c109700d internal/mailsubmit/verb.go Mount legacy accepted-legacy accepted-legacy;rev3=census-ruling-platform-mail-submission;basis=Task 4, new: POST /v1/mail on an instance's control socket. The bearer by the existing verbs' rule (empty or unreadable token refuses everything; SHA-256 constant-time compare); MaxBytesReader(14 MiB), the JSON envelope, base64 raw of at most 10 MiB, 1 to 50 non-empty recipients, a non-empty from, else 400 BAD_REQUEST; at most 2 messages per socket in the agent at once, the next 429 RATE (review round 1, Task 4 P3). Stamps account, app and host from the route the socket was bound for, never from the body, and forwards; a transport error or an answer outside 200/400/403/429/503 is 503 MAILER_UNAVAILABLE. Runs in the agent, as carlos; the body is a tenant's and is only decoded and forwarded, never used to name a path, route or account. registry:App@152,registry:Host@160,whole:Route@147 d981dffe0b5bd91fb4255b761b5434e22de62a37f8224d0c125906874648d7ae
+@legacy ead0c42093b81b9b0a1770f97bf0cd82b051ceccb4db0a4f3ee2cdb118f4e776 internal/mailsubmit/verb.go Mount legacy accepted-legacy accepted-legacy;rev3=census-ruling-platform-mail-submission;basis=Task 4, new: POST /v1/mail on an instance's control socket. The bearer by the existing verbs' rule (empty or unreadable token refuses everything; SHA-256 constant-time compare); MaxBytesReader(14 MiB), the JSON envelope, base64 raw of at most 10 MiB, 1 to 50 non-empty recipients, a non-empty from, else 400 BAD_REQUEST; at most 2 messages per socket in the agent at once, the next 429 RATE (review round 1, Task 4 P3). Stamps account, app and host from the route the socket was bound for, never from the body, and forwards; a transport error or an answer outside 200/400/403/429/503 is 503 MAILER_UNAVAILABLE. Runs in the agent, as carlos; the body is a tenant's and is only decoded and forwarded, never used to name a path, route or account. Fable P2-9 (2026-11-14): takes the agent's switch read (ExecBackend.MailSwitch) and answers 403 SUBMISSION_OFF before reading the body when the route's app is not switched; a package-level bound of MaxInFlight messages across every socket answers 503 MAILER_UNAVAILABLE. No read added: the switch is the agent's in-memory cache. registry:App@193,registry:Host@201,whole:Route@188 ea96879be3ed7737161f75b774458e635bcb87c919782317421f1b8b64fb8fd2
@legacy 9d438dcdbaabed1854fa668aa67b6b86f60ede58d5d3d2ba3c3dcb410a9f1976 internal/activator/backend_exec.go ExecBackend.agentOwnedVars legacy accepted-legacy accepted-legacy;rev3=J1;basis=root-route;rev3=census-ruling-stateless-replicas-1;basis=Task 3a: Use the verified generation/launch mode to remove CARLOS_DB after environment merges and omit the binary --db argument where applicable. Existing runtime, layout, secrets and exec gates remain; route reads are mode projection only.;rev3=census-ruling-platform-mail-submission;basis=Task 4: also decides CARLOS_MAIL through mailSubmits: set to "submit" only when the control socket bound, the verb is mounted, the app sender's switch is on and the route is Provisioned; stripped otherwise, a tenant-supplied value from fileEnv included. agentOwnedNames and moves.AgentOwnedVars gain it as a pinned pair. Only narrows what a tenant's files can set. Agent, not root. registry:Host@1209,whole:Route@1171,whole:Route@631 7cc1bcb0b415ee478350a0519799542e0b1e5419c94121519c6e1b349d613c10
@legacy 1f1d689a9e588993d353a6b73ee82dc3821e4ddeedf24c8a1662ac724b84283b internal/activator/backend_exec.go ExecBackend.spawnChildFrom legacy accepted-legacy accepted-legacy;rev3=census-ruling-zddr3;basis=Census ruling zddr3: changed legacy row (comment-only change describing the shim placement); the same class as the accepted-legacy Manager.startIn and placementLive under fix1-merge-review (existing agent delegated-cgroup management remains legacy); no root decision; no registry, /data, release or claim reads. Boundary: the agent's own delegated cgroup subtree (including its scratch probe child), /proc/self, and pipes to and from its own parent, running as carlos.;rev3=census-ruling-region-ha-p1a;basis=the agent as carlos (the flat start body): the same change as seedChild: ensureAdminTokenFor(ctx, rt, paths) for the token (the same flat path), the key's producer carrying the HA mint decision, and launchEnvLayer(ctx, rt) for the env and key layer the replica gate reads; a non-HA host's token, key and env are produced and read as before; +whole:Route; only adds refusals for HA hosts;rev3=census-ruling-stateless-replicas-1;basis=Task 3a: Use the verified generation/launch mode to remove CARLOS_DB after environment merges and omit the binary --db argument where applicable. Existing runtime, layout, secrets and exec gates remain; route reads are mode projection only.;rev3=census-ruling-edge-page-cache-1;basis=the control listener is now built with the whole route (edge.ListenControl(controlSocket, rt, ...)), the +whole:Route site; it computes the launch inputs once from the build it execs by path (a staged exe's caller-named build, or the gate-resolved pinned version; "" for an unpinned live link) and fileEnv it already read, keeps them on the childProc, and for a live-link spawn publishes them to the in-memory cache (NoteProcessInputs) beside the existing purge; no new file read;rev3=census-ruling-gvisor-demos;basis=Task 5: gate launch using startup-captured mode and existing route/role/layout before preparation or execution; migrate structured root start identity and reject mismatches. Unsupported gVisor paths refuse; native behavior and existing root authority checks retained. No new root read source. Merge2 e8a1ddde: retain main build parameter, pinned live identity, launchInputs from captured build/environment, and current-process input publication. edge.ListenControl now receives the whole Route as main requires (+whole:Route); no new filesystem or storage input. Branch sandboxLaunch remains before preparation and spawn; existing direct primitive gate unchanged.;rev3=census-ruling-security-review-mitigations;basis=Enforce the unchanged never-served resident refusal once at the shared flat/foreign primary binary spawn sink, before placement, live-link/token/env/control preparation or execution. Covers plain, generation and staged Service wakes; existing served/explicit-flat exemptions and other gates retained. No new filesystem/store source.;rev3=census-ruling-instance-gomemlimit-991;basis=#991: the agent as carlos (flat exec child): resolves the zero tier once with the existing b.tier(rt) live-tier read (the +whole:Route site) and passes it to spawnInCgroupAtTier, which previously made the same read itself. Inside the build closure (which the cgroup manager calls after writing the limits) it asks cgroup.Manager.Capped(host, child, tier), a read of memory.max in the agent's own delegated cgroup subtree, and only when that reads back as the tier adds GOMEMLIMIT=GoMemLimitOf(tier.MemoryMax) to the child env, unless the app's fileEnv names it. No delegation, a cgroup that could not be made, or a failed memory.max write gives no default (Astra R1 P2-1). Containment behaviour unchanged; no gate moved or weakened; no registry, /data, release or store read added.;rev3=census-ruling-platform-mail-submission;basis=Task 4: the inline mount (Timers, UpdatesReader) is replaced by b.controlMount(rt, tokenReader, n): the same verbs under the same conditions, plus the mail verb when b.Mail is set. The three rt.Host reads move into controlMount; the route is passed whole. Agent, not root; nothing else changes. Task 6: also calls warnUndeclaredMailBuild with the route and the version being spawned (a log line and an instance event, never a refusal). file:Command@11633,registry:Host@13029,registry:Host@13390,registry:Host@13484,registry:Host@258,registry:Host@4236,registry:Stateless@11564,whole:Route@11456,whole:Route@11605,whole:Route@12126,whole:Route@13781,whole:Route@13873,whole:Route@1527,whole:Route@189,whole:Route@1944,whole:Route@2305,whole:Route@287,whole:Route@4091,whole:Route@4119,whole:Route@4430,whole:Route@476,whole:Route@6501,whole:Route@7027,whole:Route@9259,whole:Route@9383,whole:Route@9432 3d41b02bd489afc873fb9b89d214dc338348aea37fb3de8a138dc26cde6b69ad
@legacy f8548413a8fdccad95a1cd9c588a06c14b54de6eb4d3208fbb72495308946c97 internal/activator/backend_exec.go ExecBackend.spawnUnitFrom legacy accepted-legacy accepted-legacy;rev3=census-ruling-carlos-run;basis=Re-digested at the pre-land merge: the body includes main's own change under census ruling 292, with no further change from this branch. the agent (/opt/carlos/carlos agent, carlos-edge.service, user carlos): main's body; it calls prepareKeyedAt and keeps the launch environment and its key layer on the generation's handle; read sites unchanged, offsets moved;rev3=census-ruling-wake-latency-2;basis=times the launch's steps with time.Now() (build, prepare, launch file, gate, root start) and adds them to its existing "started" journal line; no read added or moved;rev3=census-ruling-rootfs-apps-2;basis=the unit names in its error and log lines go through runUnitName, and newUnitProcFor's new error (a role with no unit to observe) fails the start as markStartUncertain after root started the unit; the binary spawn is otherwise unchanged, a rootfs row never reaches it (nestedGate refuses one); no read added;rev3=census-ruling-stateless-replicas-1;basis=Task 3a: Use the verified generation/launch mode to remove CARLOS_DB after environment merges and omit the binary --db argument where applicable. Existing runtime, layout, secrets and exec gates remain; route reads are mode projection only.;rev3=census-ruling-edge-page-cache-1;basis=computes the page cache launch inputs once (launchInputs: sha256 over the staged or pinned exe's Version and the fileEnv this spawn already read; "" with no exe, since root binds the movable live link) and keeps them on the unit handle (up.inputs); no new file, registry or bucket read; read sites unchanged (29); no read added;rev3=census-ruling-gvisor-demos;basis=Task 5: gate launch using startup-captured mode and existing route/role/layout before preparation or execution; migrate structured root start identity and reject mismatches. Unsupported gVisor paths refuse; native behavior and existing root authority checks retained. No new root read source. Merge2 e8a1ddde: retain main launchInputs computed from the captured file environment and pinned/staged build and store them on the handle, alongside branch sandbox gate, validated root StartResponse Unit/Sandbox/InvocationID and all uncertain-start cleanup. No new direct read.;rev3=census-ruling-fix-silent-start-kill-861;basis=#861: one log line before killFailedGen naming the host, the generation unit (runUnitName) and the error already in hand; the +registry:Host sites are those two arguments to log.Printf; no new read source, behaviour unchanged;rev3=census-ruling-instance-gomemlimit-991;basis=#991: the agent as carlos (nested start): resolves the zero tier once (b.tier(rt), the existing live-tier read), adds GOMEMLIMIT=GoMemLimitOf(tier.MemoryMax) to the launch file env unless the app's fileEnv already names it (withGoMemLimit; skipped under gVisor, where root supplies its own and drops any launch value), passes that same tier to startRole, and logs it. No new read source; root still validates memory_max against the size table; read sites unchanged.;rev3=census-ruling-platform-mail-submission;basis=Task 6: calls warnUndeclaredMailBuild with the route and the version being spawned. Logs and emits an instance event once per (host, version) when the app is switched and the staged manifest does not declare --mail submit; never refuses. Agent, not root. registry:Host@1308,registry:Host@2277,registry:Host@2382,registry:Host@2513,registry:Host@2970,registry:Host@4046,registry:Host@4407,registry:Host@5175,registry:Host@5761,registry:Host@6026,registry:Host@6183,registry:Host@6204,registry:Host@6425,registry:Host@6610,registry:Host@7005,registry:Host@7266,registry:Host@7375,registry:Host@8374,registry:Host@8468,registry:Stateless@2327,whole:Route@1093,whole:Route@1472,whole:Route@1714,whole:Route@197,whole:Route@2127,whole:Route@2367,whole:Route@3027,whole:Route@3082,whole:Route@4282,whole:Route@431,whole:Route@6258,whole:Route@7455,whole:Route@995 ddbf6eef60b08fca97a3b63af8a931efb73e014392059996073d41811b488493
@@ -45,9 +46,10 @@
cli.go runShip legacy accepted-legacy accepted-legacy;rev3=J4;basis=root-input;rev3=census-ruling-rootfs-apps-1;basis=rootfs Plan 1 Task 9: takes --rootfs, --processes, --hibernate, --jit and --check and hands a rootfs ship to runShipRootfs (ship_rootfs.go) before the binary path; the --notes-file ReadFile moved into shipNoteText (its own row, the same read of the file the person named) and the direct-mode version mint into mintDirectVersion; one read site fewer, none added; Task 12: the --hibernate flag help is RFS-1-C32's new text, the same reads;rev3=census-ruling-edge-asset-cache-1;basis=takes --assets (repeatable), checks the folders with checkShipAssets (release.ValidAssetPaths; refused on a static site) before the mode split, carries them into the API meta (sess.shipAssets) and the direct-mode manifest (shipAssetsBlock), and passes them to runShipRootfs (rootfsShipOpts.assets), which runs the same check and carries them the same two ways; after a direct-mode ship has stored a release declaring folders, directShipAssetGens runs the console ship door's backfill (provision.MintMissingAssetGens: lists the app's record keys and gives each record without an asset generation one, a CAS write in the deployment bucket as the person running the CLI) and fails naming any record it could not mint; read sites unchanged (2), none added;rev3=census-ruling-rootfs-apps-4;basis=adds the repeatable --env flag and refuses it before anything else unless --check is given (shipEnvRefusal, parseShipCheckEnv); the parsed values go into rootfsShipOpts.checkEnv. --env values reach the check's local container runtime as -e argv only, never root, never a box. No read added; read sites unchanged (2).;rev3=census-ruling-stateless-replicas-1;basis=Carry --stateless into binary/API and rootfs ship options; same two read sites, no new read.;rev3=census-ruling-platform-mail-submission;basis=Task 6: a --mail flag (only "submit" accepted, refused with one line otherwise, and refused with --rootfs), set on the manifest in direct-bucket mode and sent to the console in API mode, where a console that does not echo it is refused (ship_mail.go, apimode.go), as --stateless is. A person's ship command; no root read, no box state. file:ReadFile@8054,file:ReadFile@8278 342325f3f6dcd03f09a75513df923a3b669eaef37e8c86ba699f037e21b6ee18
infra/modules/region-host/outputs.tf external legacy accepted-legacy accepted-legacy;rev3=J4;basis=root-input;rev3=census-ruling-region-ha-p3b;basis=Keep fixed outputs through indexed resources, return null for group instance/EIP, and expose group, pinned template, ingress and boot-parameter names. Operator Terraform outputs only; no new box read.;rev3=census-ruling-region-ha-g2-fixes;basis=Expose the module alert topic ARN, null without an alerts topic; no new box runtime read.;rev3=census-ruling-region-ha-g3-fixes;basis=Return the selected existing or module-created alert topic ARN, null when neither input is set. Terraform output only; no new root runtime read.;rev3=census-ruling-managed-fleets-2b1;basis=managed fleets 2b-1 Task 5: three outputs, managed_fleet_user_boundary_arn, managed_fleet_user_path and managed_fleet_bucket_prefix, each null unless managed_fleets_enabled; Terraform outputs for the operator only; no box runtime read is added;rev3=census-ruling-w6-ingress-drain;basis=new output ingress_target_groups: the ARNs joined with commas in fixed mode when set, null otherwise and in group mode; the operator copies it into the box's host.env (CARLOS_INGRESS_TARGET_GROUPS) by hand. Output only; no read added.;rev3=census-ruling-platform-mail-submission;basis=Task 8: output "mailer_user_name", the user's name or null. Read-only. file:external@0 fc7a4e1f10e52775047a9b0cedb636a00641e8f6831970baefea419871be9868
infra/modules/region-host/variables.tf external legacy accepted-legacy accepted-legacy;rev3=census-ruling-console-invite-delivery;basis=tofu on an operator's machine with the operator's AWS credentials (no box unit; no binary embeds the file): main's variables with console_mail_from (validated as one lowercase address) and console_mail_region, both empty by default; no read is added and nothing on a box reads the file;rev3=census-ruling-hunt-account-root-hardening;basis=adds deny_release_key_reads (bool, default true); no read is added and nothing on a box reads the file;rev3=census-ruling-region-ha-p3b;basis=Add default-fixed mode and validated group count, zones, pinned image/release/template, ingress, configuration key and transaction-open refusal. Operator-supplied Terraform values select root boot inputs; no direct box runtime read and no group activation by default.;rev3=census-ruling-region-ha-g2-fixes;basis=Add an empty-default set of additional alert topic ARNs, validating concrete SNS topic syntax and excluding wildcards/subscriptions; operator Terraform input, no box runtime read.;rev3=census-ruling-region-ha-g3-fixes;basis=Add optional alerts_topic_arn with concrete same-region SNS ARN validation and mutual exclusion with alerts_email. The caller owns the existing topic policy and subscriptions; no runtime sink is configured and no new root read is added.;rev3=census-ruling-managed-fleets-2b1;basis=managed fleets 2b-1 Task 5: five variables, managed_fleets_enabled (bool, default false, refused unless mode is fixed), managed_fleets_deployment, managed_fleets_regions (concrete ami/subnet/sg IDs, arm64 types, no ID in two regions), managed_fleet_bucket_prefix (1-24 chars, no reserved prefix, must not cover the deployment, data or staging buckets, disjoint from store_bucket_prefix) and managed_fleet_user_path (literal IAM path, disjoint from store_user_path); store_bucket_prefix and store_user_path gain a validation refusing *, ? or ${ only when managed fleets and object storage are both on; operator Terraform input only; no box runtime read and nothing on a box reads the file;rev3=census-ruling-fixedbox-health-alarms;basis=Add optional health_alerts_topic_arn (concrete same-region SNS ARN validation, empty default); enable_auto_recovery description covers both status alarms. Operator Terraform input; no box runtime read.;rev3=census-ruling-w6-ingress-drain;basis=new variable ingress_target_group_arns (list(string), default [], non-nullable) validated as distinct ELB target group ARNs (arn:aws(-x)*:elasticloadbalancing:<region>:<12 digits>:targetgroup/<name>/<16 hex>); drives the IAM policy and output above. No read added.;rev3=census-ruling-stats-prune-400;basis=new variable enable_analytics_version_prune (bool, default false) driving the policy above; operator Terraform input; no box runtime read;rev3=census-ruling-platform-mail-submission;basis=Task 8: variable "mailer", an object {ses_region, ses_account_id, deployment_bucket_region, optional deployment_bucket_kms_key_arn} defaulting to null, which creates nothing; validated (AWS region shapes, 12-digit account, KMS ARN or empty). file:external@0 4e3076d5835fcd03f51edcd5f6847371c2f2059598b4bf7841cba2aead5b3754
+internal/activator/cmdunit.go ExecBackend.cmdVars legacy accepted-legacy accepted-legacy;rev3=census-ruling-carlos-run;basis=the agent (/opt/carlos/carlos agent, carlos-edge.service, user carlos): composes the command's environment over the serving generation's launch snapshot; the host comes from the row, never from a tenant file;rev3=census-ruling-stateless-replicas-1;basis=Task 3a: Use the verified generation/launch mode to remove CARLOS_DB after environment merges and omit the binary --db argument where applicable. Existing runtime, layout, secrets and exec gates remain; route reads are mode projection only.;rev3=census-ruling-platform-mail-submission;basis=Fable P3 (2026-11-14): a cmd one-shot's environment also strips CARLOS_MAIL, as seedVars does: a one-shot has no control socket, so it cannot submit mail. Only narrows what a run is given; no read added. Agent, not root. registry:Host@356,whole:Route@462 75f3a85e8bdbb5a27b22eeb094135628e315d4c4c80482040b836ceb44955ad9
internal/host/agent.go fastTick legacy accepted-legacy accepted-legacy;rev3=J1;basis=root-route;rev3=PROPOSED-s3-change-index;identity=the agent (/opt/carlos/carlos agent, carlos-edge.service, user carlos);basis=observes the change index before any pass (observeIndex), runs the backstop's requested full pass and a scoped pass for moved app scopes (indexTick), and arms the canary pointer gate on the sweep (canaryPointerGate) only on a tick whose own index observation succeeded; read site unchanged, offset moved;rev3=census-ruling-stateless-replicas-1;basis=Call coordinator Tick on the existing tick before convergence; client renews held terms only at the pinned interval. Existing registry read unchanged. Final review I3: signal the owned renewal worker instead of waiting for its sequential console HTTP calls. Existing convergence and record read unchanged.;rev3=census-ruling-region-ha-p3a;basis=Run the optional desired-role reader on the existing tick after observing the armed change index; no new root path or timer, nil reader is unchanged.;rev3=census-ruling-stateless-replicas-2;basis=Slice 3b: signals the owned replica worker on the existing tick; coalesced asynchronous execution, no timer or bucket scan added. merge of origin/main 7920cccf: Retain main box-role reader pass on the existing tick alongside the replica worker signal; merge-only body change, unchanged read sites.;rev3=census-ruling-restart-new-box-gap;basis=calls the optional restartGain hook (restartGainSeed) once per existing tick before the serial read; no new root path, timer or read kind; nil hook is unchanged;rev3=census-ruling-agent-start-demo-3;basis=Refresh moved notices through the shared watch before normal convergence; no new per-box poll. Census read-site delta: unchanged (1).;rev3=census-ruling-stateless-replicas-4-task1;basis=Signals the owned replica swap worker (armedReplicaDeploy.tick) beside the placement worker on the existing tick; coalesced background pass, no timer, no bucket read. Its transitions go through the console's authenticated /deploy.;rev3=census-ruling-platform-mail-submission;basis=Task 4: on a serial move, after the schedule leg, starts the armed mail switch cache's Refresh on its own goroutine (each read bounded at 2 s, overlapping refreshes skipped). It re-reads the app sender records already cached, through the agent's deploy store. Agent, not root; the tick waits on nothing new. registry:Host@5822 a1cd273f24047c63670f8c32c000a84f1a3861d058da38c5318551929f312390
internal/host/agent.go provisionTickConfig legacy accepted-legacy accepted-legacy;rev3=J4;basis=root-input;rev3=census-ruling-ha-p1a-433;basis=the agent (carlos-edge.service, user carlos) and the edges file loop's eligibility: the same CARLOS_POOLS read, now parsed by provision.ParseBoxPools (internal/provision, envelope re-pinned), the one parser boxPools also uses. "@shared" (provision.SharedPoolToken, never a valid pool name) is the shared "" pool; other tokens are literal as before; empty elements and repeats dropped. No read added.;rev3=census-ruling-managed-fleets-1b;basis=managed fleets 1b (Task 4, rule 2): sets ReconcileConfig.FleetBox to the box's own fleet label from resolveFleetIdentity(getenv), only when the identity resolves and region == PlacementTarget(identity.Fleet); otherwise it stays "" (the box admits only unlabelled records). The same environment the fleet loops already read; read sites unchanged (2). Agent config, not root.;rev3=census-ruling-platform-mail-submission;basis=Task 5: its region, pools and fleet label now come from BoxScopeFromEnv, which is the same three reads moved out unchanged (CARLOS_REGION trimmed, provision.ParseBoxPools(CARLOS_POOLS), and resolveFleetIdentity's label only when its fleet is the one the region places the box on), so the box-local mailer resolves "on this box" by the agent's rule. The ReconcileConfig it returns is field for field what it was. Agent, not root. data-literal@173,data-literal@214 cabe3cb9662118eb82ddbc77dbbdb80b6718494caea097c8ffb894ccc4903fe3
-internal/host/agent.go statusLoop legacy accepted-legacy accepted-legacy;rev3=census-ruling-self-serve-moves-1;basis=the agent (/opt/carlos/carlos agent, carlos-edge.service, user carlos): the status tick's context carries the box's lifetime judge; read sites unchanged, offsets moved;rev3=census-ruling-rootfs-apps-2;basis=main's body as of the merge of origin/main 953b9fda (its later changes, regional box names and self-serve moves plan 1 among them, under main's own census rulings), where the tick fills rootfs_ready and rootfs_blocked from armedRootfs.Load().probe, which each tick runs NestedOK's checks and asks the control socket's GET /ready/rootfs (never the store); the same four direct sites;rev3=census-ruling-instance-egress-sizes-328-329;basis=#328 plan 2 Task 11 and #329 plan 3 Task 7: takes root's GET /egress reader and fills p.Egress = egressStatusProbe(egressStatus, routes, provision.PolicyReadStates()) and p.SizeCommittedMiB = sizeCommittedMiB(armedSizeSource.Load(), routes); the two added whole:Route sites are the tick's own registry list handed to those two units (decision rows), which read root's control socket and the activator's memory; no store request added; the four existing sites unchanged, offsets moved.;rev3=census-ruling-fleet-alerts-1;basis=the agent (carlos-edge.service, user carlos): the status tick passes os.Geteuid() to alertDeliveryProbe, which fills AlertDelivery.EngineBeat/EngineBeatWhy from engineBeatArmed (the env value and the euid only, no file access, root refused before the path is looked at), and fills Probes.DiskFullETAHours from diskETAProbe(&processDiskTrend, now), a Theil-Sen fit over the metrics loop's in-memory ring of disk readings; the same six sites, no read added, no store request added;rev3=census-ruling-edge-held-streams;basis=the agent (/opt/carlos/carlos agent, carlos-edge.service, user carlos): the status tick's Probes gain HeldStreams: heldStreamsState(), which calls the edge's in-memory counters function (nil until the edge is ready). No file, bucket or registry access added.;rev3=census-ruling-stateless-replicas-3;basis=Fix round 1 Q20: read the detached in-memory replica snapshot source into Probes.ReplicaCopies on the existing five-minute tick. Existing six direct read sites unchanged. No additional bucket request, changed cadence or app lifecycle action.;rev3=census-ruling-agent-start-demo-3;basis=Report moved capability only when the serving edge reports readiness; report claim-seed support only with CARLOS_DEMO_CLAIM=1. Reads the explicit capability flag from the process environment; no new filesystem or registry read.;rev3=census-ruling-stateless-replicas-4-task5;basis=Task 5 fix round 1 (#511 R16 amendment): the status tick also fills Probes.ApplyFinished from systemApplyFinished(release.OptDir()), an Lstat of root's apply journal <opt>/system/router/journal.json in the root-owned, world-readable state directory: finished only when the journal is absent, any other answer unknown and so unfinished. Round 0: Probes.PrevRelease from prevReleaseOf (carlos.prev and carlos.prev.version, the files withMovesFields already reads). Reported in the private BoxMetrics block; no bucket request or cadence change.;rev3=census-ruling-offline-move-stage-refusals-339;basis=#339: the agent (carlos-edge.service, user carlos): the status tick fills p.OfflineMove = offlineMoveFactsProbe(routes); the added whole:Route site is the tick's own registry list handed to that unit, which under a non-root euid lists the names of root's <opt>/live and nothing else; no store request added.;rev3=census-ruling-platform-mail-submission;basis=Task 3 (plan gap G6 (b)): the status tick also fills Probes.MailerArmed from mailerArmed(mailwire.MailerSocket, 2s): a stat of /run/carlos-mailer/mailer.sock and, only when it is a socket, GET /v1/health on it. The agent (carlos-edge.service, user carlos), not root; reported in the private BoxMetrics block only. The same six sites; no store request, no read of /etc/carlos-mailer (which uid carlos cannot traverse). whole:Route@10554,whole:Route@12628,whole:Route@12909,whole:Route@13267,whole:Route@6583,whole:Route@6610,whole:Route@7918 352bd5962a711a29f0f0f2f0d5e4d0a9a58f41ebf049e4f37ff41c31a4ea4eae
+internal/host/agent.go statusLoop legacy accepted-legacy accepted-legacy;rev3=census-ruling-self-serve-moves-1;basis=the agent (/opt/carlos/carlos agent, carlos-edge.service, user carlos): the status tick's context carries the box's lifetime judge; read sites unchanged, offsets moved;rev3=census-ruling-rootfs-apps-2;basis=main's body as of the merge of origin/main 953b9fda (its later changes, regional box names and self-serve moves plan 1 among them, under main's own census rulings), where the tick fills rootfs_ready and rootfs_blocked from armedRootfs.Load().probe, which each tick runs NestedOK's checks and asks the control socket's GET /ready/rootfs (never the store); the same four direct sites;rev3=census-ruling-instance-egress-sizes-328-329;basis=#328 plan 2 Task 11 and #329 plan 3 Task 7: takes root's GET /egress reader and fills p.Egress = egressStatusProbe(egressStatus, routes, provision.PolicyReadStates()) and p.SizeCommittedMiB = sizeCommittedMiB(armedSizeSource.Load(), routes); the two added whole:Route sites are the tick's own registry list handed to those two units (decision rows), which read root's control socket and the activator's memory; no store request added; the four existing sites unchanged, offsets moved.;rev3=census-ruling-fleet-alerts-1;basis=the agent (carlos-edge.service, user carlos): the status tick passes os.Geteuid() to alertDeliveryProbe, which fills AlertDelivery.EngineBeat/EngineBeatWhy from engineBeatArmed (the env value and the euid only, no file access, root refused before the path is looked at), and fills Probes.DiskFullETAHours from diskETAProbe(&processDiskTrend, now), a Theil-Sen fit over the metrics loop's in-memory ring of disk readings; the same six sites, no read added, no store request added;rev3=census-ruling-edge-held-streams;basis=the agent (/opt/carlos/carlos agent, carlos-edge.service, user carlos): the status tick's Probes gain HeldStreams: heldStreamsState(), which calls the edge's in-memory counters function (nil until the edge is ready). No file, bucket or registry access added.;rev3=census-ruling-stateless-replicas-3;basis=Fix round 1 Q20: read the detached in-memory replica snapshot source into Probes.ReplicaCopies on the existing five-minute tick. Existing six direct read sites unchanged. No additional bucket request, changed cadence or app lifecycle action.;rev3=census-ruling-agent-start-demo-3;basis=Report moved capability only when the serving edge reports readiness; report claim-seed support only with CARLOS_DEMO_CLAIM=1. Reads the explicit capability flag from the process environment; no new filesystem or registry read.;rev3=census-ruling-stateless-replicas-4-task5;basis=Task 5 fix round 1 (#511 R16 amendment): the status tick also fills Probes.ApplyFinished from systemApplyFinished(release.OptDir()), an Lstat of root's apply journal <opt>/system/router/journal.json in the root-owned, world-readable state directory: finished only when the journal is absent, any other answer unknown and so unfinished. Round 0: Probes.PrevRelease from prevReleaseOf (carlos.prev and carlos.prev.version, the files withMovesFields already reads). Reported in the private BoxMetrics block; no bucket request or cadence change.;rev3=census-ruling-offline-move-stage-refusals-339;basis=#339: the agent (carlos-edge.service, user carlos): the status tick fills p.OfflineMove = offlineMoveFactsProbe(routes); the added whole:Route site is the tick's own registry list handed to that unit, which under a non-root euid lists the names of root's <opt>/live and nothing else; no store request added.;rev3=census-ruling-platform-mail-submission;basis=Task 3 (plan gap G6 (b)): the status tick also fills Probes.MailerArmed from mailerArmed(mailwire.MailerSocket, 2s): a stat of /run/carlos-mailer/mailer.sock and, only when it is a socket, GET /v1/health on it. The agent (carlos-edge.service, user carlos), not root; reported in the private BoxMetrics block only. The same seven sites; no store request, no read of /etc/carlos-mailer (which uid carlos cannot traverse). whole:Route@10554,whole:Route@12628,whole:Route@12909,whole:Route@13267,whole:Route@6583,whole:Route@6610,whole:Route@7918 352bd5962a711a29f0f0f2f0d5e4d0a9a58f41ebf049e4f37ff41c31a4ea4eae
internal/host/bootstrap.go bootstrapWithGroup legacy accepted-legacy accepted-legacy;rev3=census-ruling-region-ha-p3b;basis=Move bootstrapWith body here, retaining host.env, embedded unit reads and tmpfiles execution. Group live caller holds root mutation guard; skip automatic update/recovery units, preserve Restart=no/nftables drop-in and masks, and write separate root-owned /run/carlos-group-maintenance tmpfiles rule outside service ownership walk. No agent receipt read.;rev3=census-ruling-gvisor-demos;basis=Create the rootfs parent at 0700 and runtime root at 0755. Existing host.env/unit reads unchanged; workload templates remain unarmed.;rev3=census-ruling-platform-mail-submission;basis=Task 3: the sysusers.d/carlos.conf it writes is now the constant sysusersConf, which adds "u carlos-mailer - \"CARLOS mailer\" - /usr/sbin/nologin" ahead of the existing "g carlos-sockets -" line, so the tmpfiles line naming group carlos-mailer resolves on a box whose confs arrive by a staged-tree refresh. Constant text, no input; no read added. file:Command@12045,file:ReadFile@564,file:ReadFile@7111 62fa76ad0fa812a0effc7c6add43ddcf54313450c13f20fbb2fee9d004488588
internal/host/bootstrap.go const tmpfilesConf authority A,C,G,J4 root-input;kept=A,C,G;scope=protected-decision-only;rev3=census-ruling-platform-mail-submission;basis=Task 3: two constant lines, "d /run/carlos-mailer 0750 root carlos -" (the mailer's socket directory, beside /run/carlos-control and shaped like it) and "d /etc/carlos-mailer 0750 root carlos-mailer -" (the key directory, which uid carlos cannot traverse). Root creates two root-owned directories; no file inside either is created, owned or seeded (the key is the operator's, by hand). No input; no read added. data-literal@1237,data-literal@1309,data-literal@1927,data-literal@21,data-literal@2328,data-literal@311,data-literal@810 d9849c0d887ce4c8698d67dfc9cf136f5b9922300b058fda6186d2fd4b42411a
internal/host/bootstrap.go privilegedPlan legacy accepted-legacy accepted-legacy;rev3=J4;basis=root-input;rev3=census-ruling-platform-mail-submission;basis=Task 3: one more constant argv, useradd --system --user-group --no-create-home --shell /usr/sbin/nologin carlos-mailer, right after carlos's, behind runPrivileged's existing guard (user.Lookup of the argv's own last word). No input; no read added. data-literal@382 4f353dc38a329ff88fdec4bc2611c44b7ac483eee308b73f58100abc539707cc
@@ -66,12 +68,12 @@ internal/status/snapshot.go CollectBox legacy accepted-legacy accepted-legacy;re
infra/modules/region-host/mailer.tf external legacy accepted-legacy accepted-legacy;rev3=census-ruling-platform-mail-submission;basis=Task 8, new: with var.mailer set (default null: nothing), aws_iam_user.mailer carlos-mailer-<region> at path /carlos-mailer/ (precondition: ses_account_id is the module's own account) and aws_iam_user_policy.mailer with ses:SendRawEmail on identity/*, configuration-set/carlos-* and tenant/carlos-*/* in ses_region (the tenant per Task 8 review P2-1, as the console's own policy grants its tenant), and s3:GetObject on apps/*/*/email/senders/*, apps/*/*/instances/* and accounts/*/email/domains/* (plus kms:Decrypt via S3 only when a bucket KMS key is given). No s3:ListBucket, no write, no IAM action, no access key resource (the key never enters state). The host role gains nothing. In group mode two String region parameters, CARLOS_MAIL_REGION and CARLOS_DEPLOYMENT_REGION, under the region's existing /carlos/<deployment>/<region>/ path, which host-env write --group already reads and validates against hostenv's allowlist. References no sibling script; nothing a box's root runs or reads beyond those two plain values. file:external@0 a48c782bf4f63f5121c6ccae7d19793f0af4c9f9856127319f6bb9014357890f
infra/modules/region-host/tests/mailer.tftest.hcl external legacy accepted-legacy accepted-legacy;rev3=census-ruling-platform-mail-submission;basis=Task 8, new: plan-only runs under mock_provider: off by default; the user's name and path; the policy's two statements exactly; no ListBucket, Put, delete, SendEmail, IAM or wildcard action; KMS adds decrypt through S3 only; another account refused; a bad region refused; the host role gains no SES. Test-only. file:external@0 d8f1e5acb446a2e33848958b3ea036ab81c1f17565ab8df5409883b0afb39164
infra/modules/region-host/tests/mailer_group.tftest.hcl external legacy accepted-legacy accepted-legacy;rev3=census-ruling-platform-mail-submission;basis=Task 8, new: plan-only runs under mock_provider with group.tftest.hcl's fixtures (plus an AMI override): the two region parameters' names and values with mailer set, none without. Test-only. file:external@0 c36b70fc72d0b317db438c66a7e669a49a92ddce904ae8307f3503031c53f73f
-internal/activator/backend_exec.go ExecBackend.controlMount legacy accepted-legacy accepted-legacy;rev3=census-ruling-platform-mail-submission;basis=Task 4, new: the one composer of a control socket's verbs, for both bind sites. Mounts the schedule verbs and GET /updates exactly as the two inline copies did (same conditions, same host, token reader and write fence), and POST /v1/mail (mailsubmit.Mount) under its own condition, b.Mail != nil. Reads rt.Host and passes the route to Mount; returns nil when nothing is mounted. The agent (carlos-edge.service, user carlos), not root. registry:Host@292,registry:Host@347,registry:Host@426,whole:Route@515 827650c1147231c19b6da7e41f3fc97fa4c28e3eda76961dfa788bc9c25f536e
+internal/activator/backend_exec.go ExecBackend.controlMount legacy accepted-legacy accepted-legacy;rev3=census-ruling-platform-mail-submission;basis=Task 4, new: the one composer of a control socket's verbs, for both bind sites. Mounts the schedule verbs and GET /updates exactly as the two inline copies did (same conditions, same host, token reader and write fence), and POST /v1/mail (mailsubmit.Mount) under its own condition, b.Mail != nil. Reads rt.Host and passes the route to Mount; returns nil when nothing is mounted. The agent (carlos-edge.service, user carlos), not root. Fable P2-9: passes b.MailSwitch to mailsubmit.Mount. No read added. registry:Host@292,registry:Host@347,registry:Host@426,whole:Route@515 df735c417720309504a5623549c6f02ec8050bcbdcb8b42d05ef31380710ca93
internal/activator/backend_exec.go ExecBackend.mailSubmits legacy accepted-legacy accepted-legacy;rev3=census-ruling-platform-mail-submission;basis=Task 4, new: the CARLOS_MAIL rule. Reads rt.App, rt.Host, rt.Provisioned and RouteAccount(rt) from the agent's own registry row, and asks b.MailSwitch (the agent's cache of the console-written app sender record, internal/host/mailswitch.go: one bounded Get of apps/<acct>/<app>/email/senders/app.json through the agent's deploy store). Logs once per host at error level for an unprovisioned route of a switched app. Agent, not root; no file read. registry:App@213,registry:App@526,registry:Host@317,registry:Host@511,registry:Provisioned@246,whole:Route@185 cfd7494b38dc64c2710233dbc2da850eb7b89fc9aecfa648cd7affd5e9a354d0
internal/activator/mailbuild.go ExecBackend.warnUndeclaredMailBuild legacy accepted-legacy accepted-legacy;rev3=census-ruling-platform-mail-submission;basis=Task 6, new: design decision 10's loud log, never a refusal (a refused wake would turn a mail gap into a site outage). Asks the agent's switch cache (MailSwitch) and reads the staged manifest of the version being spawned through ManifestOf (release.ReadStagedManifest, the read TierOf already makes); logs at error level and emits one instance event per (host, version). Agent, not root; reads only what the spawn already reads. registry:App@1201,registry:App@219,registry:App@848,registry:Host@1177,registry:Host@249,registry:Host@819,whole:Route@1228,whole:Route@191,whole:Route@368 e36bed0c8ebdd741227e4805972b569f78497105874c75832dbcb0ccf17956f3
internal/host/mailerreport.go mailerArmed legacy accepted-legacy accepted-legacy;rev3=census-ruling-platform-mail-submission;basis=Task 3, new: the agent's MailerArmed probe. Stats the constant socket path and dials it for GET /v1/health with a 2 s timeout; true only on a 200. Runs in the agent as carlos, never as root; the path is a constant, in a root-owned 0750 root:carlos directory nothing a tenant or an app can write. Answers a bool into the private status block. file:Stat@72 6fd83d5c27429d06864d02a141f7036c2f3e1e8e89366ad6d2a232d417420052
internal/host/units/carlos-mailer-arm.path external legacy accepted-legacy accepted-legacy;rev3=census-ruling-platform-mail-submission;basis=Task 3, new: [Path] PathExists=/etc/carlos-mailer/keys, Unit=carlos-mailer.socket, WantedBy=multi-user.target; enabled and armed by bootstrap like every .path. PID 1 watches a path in a root-owned 0750 root:carlos-mailer directory only root (the operator) writes; it starts a socket unit and reads nothing. file:external@0 6b28c6282ee930560f859f20c752c65f0e550412b9c6ffb1fc10c292a3941a2a
-internal/host/units/carlos-mailer.service external legacy accepted-legacy accepted-legacy;rev3=census-ruling-platform-mail-submission;basis=Task 3, new: runs /opt/carlos/carlos mailer serve as the static user carlos-mailer (never root), socket-activated, ConditionPathExists=/etc/carlos-mailer/keys, EnvironmentFile=-/etc/carlos/host.env (read by PID 1, as every carlos service's) with UnsetEnvironment= of every credential a host.env may carry (CARLOS_SECRETS_KEY, CARLOS_RELEASE_KEY, the tunnel, service, sidecar and DNS tokens, the alert webhook, CARLOS_ADMIN_TOKEN, CARLOS_INSTANCE_KEY, AWS keys and profiles; review round 1 Task 3 P3), AWS_EC2_METADATA_DISABLED=true, IPAddressDeny=169.254.169.254/32 fd00:ec2::254/128, StateDirectory=carlos-mailer 0700, and the relay's hardening block with no ReadWritePaths; Environment=GOMEMLIMIT=288MiB with MemoryHigh=320M and MemoryMax=384M for four 10 MiB sends (review round 1, Task 5 P3). No root process reads anything new; the mailer reads its own key file and state. file:external@0 4c0f0138683659416f50fbcfdbf18df6592ae03531538e2d98f9f2392659c7cb
+internal/host/units/carlos-mailer.service external legacy accepted-legacy accepted-legacy;rev3=census-ruling-platform-mail-submission;basis=Task 3, new: runs /opt/carlos/carlos mailer serve as the static user carlos-mailer (never root), socket-activated, ConditionPathExists=/etc/carlos-mailer/keys, EnvironmentFile=-/etc/carlos/host.env (read by PID 1, as every carlos service's) with UnsetEnvironment= of every credential a host.env may carry (CARLOS_SECRETS_KEY, CARLOS_RELEASE_KEY, the tunnel, service, sidecar and DNS tokens, the alert webhook, CARLOS_ADMIN_TOKEN, CARLOS_INSTANCE_KEY, AWS keys and profiles; review round 1 Task 3 P3), AWS_EC2_METADATA_DISABLED=true, IPAddressDeny=169.254.169.254/32 fd00:ec2::254/128, StateDirectory=carlos-mailer 0700, and the relay's hardening block with no ReadWritePaths; Environment=GOMEMLIMIT=288MiB with MemoryHigh=320M and MemoryMax=384M for four 10 MiB sends (review round 1, Task 5 P3). No root process reads anything new; the mailer reads its own key file and state. file:external@0 3b9c4fa4c4487653863e3140d4007a8c873b031649f9e53b318b4802305c085e
internal/host/units/carlos-mailer.socket external legacy accepted-legacy accepted-legacy;rev3=census-ruling-platform-mail-submission;basis=Task 3, new: ConditionPathExists=/etc/carlos-mailer/keys, ListenStream=/run/carlos-mailer/mailer.sock, SocketUser=carlos, SocketGroup=carlos, SocketMode=0600, Accept=no; not enabled, started only by the arming path. PID 1 binds a socket in a root-owned directory, as carlos-instance-control.socket does in /run/carlos-control. No read added. file:external@0 275aae364c39e89bdf3d76d7e66aea9cf65b398ac0c16c087db353cfd5140c34
internal/mailer/counter.go Counter.loadLocked legacy accepted-legacy accepted-legacy;rev3=census-ruling-platform-mail-submission;basis=Task 5, new: reads the day's counts file from the mailer's own state directory; a body that does not decode is renamed aside, logged loudly, and the day restarts at zero (the per-box bound §4.1 (a) accepts). carlos-mailer only. file:ReadFile@142 a317a61e58c996133e1ae96045932c927052cb5f44720fb90193ae45abbe2d1b
internal/mailer/counter.go Counter.writeLocked legacy accepted-legacy accepted-legacy;rev3=census-ruling-platform-mail-submission;basis=Task 5, new: writes the day's counts durably (temp file in the same directory, fsync, rename, directory fsync) before a send. carlos-mailer only, in its own state directory. file:CreateTemp@118,file:Open@489 40cb38a8252e6c90bd21efdfafc7bbcb9b66b04a10bf9c2154f5796e1bff4820
@@ -79,24 +81,24 @@ internal/mailer/counter.go OpenCounter legacy accepted-legacy accepted-legacy;re
internal/mailer/keys.go KeyFile.Changed legacy accepted-legacy accepted-legacy;rev3=census-ruling-platform-mail-submission;basis=Task 5, new: a stat of the same constant key path, compared with the loaded file's mtime, size and inode, so a rotation reloads with no restart. carlos-mailer only. file:Stat@47 1e4714c15a0cde077167358d786eaa3b33d6a9f3330a5d282dbba59beb1a3299
internal/mailer/keys.go loadKeys legacy accepted-legacy accepted-legacy;rev3=census-ruling-platform-mail-submission;basis=Task 5, new: reads /etc/carlos-mailer/keys (a constant path) as carlos-mailer: refuses anything but a regular 0640 file owned by root and group carlos-mailer, more than two keys, or a malformed line; errors never carry a secret. Root never reads it. The file is written by the operator by hand, in a 0750 root:carlos-mailer directory uid carlos cannot traverse. file:Open@68,file:ReadFrom@488,file:Stat@154 c86150ed82395d1051892825ea4893a289e2eda699372974c4373845794d707d
internal/mailsubmit/forward.go SocketForwarder.Send legacy accepted-legacy accepted-legacy;rev3=census-ruling-platform-mail-submission;basis=Task 4, new: the agent's client to the mailer: one HTTP POST of /v1/send over a fresh dial of the constant /run/carlos-mailer/mailer.sock, 60 s timeout, answer read to at most 64 KiB and decoded. Runs in the agent, as carlos. The socket's directory is root's; the mailer at the other end is a separate uid. file:ReadAll@885 b1c14436f42f60c4157ad0dffb1b998931a58b3a2ebf545578ff6d2e243dcd58
-internal/mailsubmit/verb.go Mount legacy accepted-legacy accepted-legacy;rev3=census-ruling-platform-mail-submission;basis=Task 4, new: POST /v1/mail on an instance's control socket. The bearer by the existing verbs' rule (empty or unreadable token refuses everything; SHA-256 constant-time compare); MaxBytesReader(14 MiB), the JSON envelope, base64 raw of at most 10 MiB, 1 to 50 non-empty recipients, a non-empty from, else 400 BAD_REQUEST; at most 2 messages per socket in the agent at once, the next 429 RATE (review round 1, Task 4 P3). Stamps account, app and host from the route the socket was bound for, never from the body, and forwards; a transport error or an answer outside 200/400/403/429/503 is 503 MAILER_UNAVAILABLE. Runs in the agent, as carlos; the body is a tenant's and is only decoded and forwarded, never used to name a path, route or account. registry:App@152,registry:Host@160,whole:Route@147 d981dffe0b5bd91fb4255b761b5434e22de62a37f8224d0c125906874648d7ae
+internal/mailsubmit/verb.go Mount legacy accepted-legacy accepted-legacy;rev3=census-ruling-platform-mail-submission;basis=Task 4, new: POST /v1/mail on an instance's control socket. The bearer by the existing verbs' rule (empty or unreadable token refuses everything; SHA-256 constant-time compare); MaxBytesReader(14 MiB), the JSON envelope, base64 raw of at most 10 MiB, 1 to 50 non-empty recipients, a non-empty from, else 400 BAD_REQUEST; at most 2 messages per socket in the agent at once, the next 429 RATE (review round 1, Task 4 P3). Stamps account, app and host from the route the socket was bound for, never from the body, and forwards; a transport error or an answer outside 200/400/403/429/503 is 503 MAILER_UNAVAILABLE. Runs in the agent, as carlos; the body is a tenant's and is only decoded and forwarded, never used to name a path, route or account. Fable P2-9 (2026-11-14): takes the agent's switch read (ExecBackend.MailSwitch) and answers 403 SUBMISSION_OFF before reading the body when the route's app is not switched; a package-level bound of MaxInFlight messages across every socket answers 503 MAILER_UNAVAILABLE. No read added: the switch is the agent's in-memory cache. registry:App@193,registry:Host@201,whole:Route@188 ea96879be3ed7737161f75b774458e635bcb87c919782317421f1b8b64fb8fd2
internal/activator/backend_exec.go ExecBackend.agentOwnedVars legacy accepted-legacy accepted-legacy;rev3=J1;basis=root-route;rev3=census-ruling-stateless-replicas-1;basis=Task 3a: Use the verified generation/launch mode to remove CARLOS_DB after environment merges and omit the binary --db argument where applicable. Existing runtime, layout, secrets and exec gates remain; route reads are mode projection only.;rev3=census-ruling-platform-mail-submission;basis=Task 4: also decides CARLOS_MAIL through mailSubmits: set to "submit" only when the control socket bound, the verb is mounted, the app sender's switch is on and the route is Provisioned; stripped otherwise, a tenant-supplied value from fileEnv included. agentOwnedNames and moves.AgentOwnedVars gain it as a pinned pair. Only narrows what a tenant's files can set. Agent, not root. registry:Host@1209,whole:Route@1171,whole:Route@631 7cc1bcb0b415ee478350a0519799542e0b1e5419c94121519c6e1b349d613c10
internal/activator/backend_exec.go ExecBackend.spawnChildFrom legacy accepted-legacy accepted-legacy;rev3=census-ruling-zddr3;basis=Census ruling zddr3: changed legacy row (comment-only change describing the shim placement); the same class as the accepted-legacy Manager.startIn and placementLive under fix1-merge-review (existing agent delegated-cgroup management remains legacy); no root decision; no registry, /data, release or claim reads. Boundary: the agent's own delegated cgroup subtree (including its scratch probe child), /proc/self, and pipes to and from its own parent, running as carlos.;rev3=census-ruling-region-ha-p1a;basis=the agent as carlos (the flat start body): the same change as seedChild: ensureAdminTokenFor(ctx, rt, paths) for the token (the same flat path), the key's producer carrying the HA mint decision, and launchEnvLayer(ctx, rt) for the env and key layer the replica gate reads; a non-HA host's token, key and env are produced and read as before; +whole:Route; only adds refusals for HA hosts;rev3=census-ruling-stateless-replicas-1;basis=Task 3a: Use the verified generation/launch mode to remove CARLOS_DB after environment merges and omit the binary --db argument where applicable. Existing runtime, layout, secrets and exec gates remain; route reads are mode projection only.;rev3=census-ruling-edge-page-cache-1;basis=the control listener is now built with the whole route (edge.ListenControl(controlSocket, rt, ...)), the +whole:Route site; it computes the launch inputs once from the build it execs by path (a staged exe's caller-named build, or the gate-resolved pinned version; "" for an unpinned live link) and fileEnv it already read, keeps them on the childProc, and for a live-link spawn publishes them to the in-memory cache (NoteProcessInputs) beside the existing purge; no new file read;rev3=census-ruling-gvisor-demos;basis=Task 5: gate launch using startup-captured mode and existing route/role/layout before preparation or execution; migrate structured root start identity and reject mismatches. Unsupported gVisor paths refuse; native behavior and existing root authority checks retained. No new root read source. Merge2 e8a1ddde: retain main build parameter, pinned live identity, launchInputs from captured build/environment, and current-process input publication. edge.ListenControl now receives the whole Route as main requires (+whole:Route); no new filesystem or storage input. Branch sandboxLaunch remains before preparation and spawn; existing direct primitive gate unchanged.;rev3=census-ruling-security-review-mitigations;basis=Enforce the unchanged never-served resident refusal once at the shared flat/foreign primary binary spawn sink, before placement, live-link/token/env/control preparation or execution. Covers plain, generation and staged Service wakes; existing served/explicit-flat exemptions and other gates retained. No new filesystem/store source.;rev3=census-ruling-instance-gomemlimit-991;basis=#991: the agent as carlos (flat exec child): resolves the zero tier once with the existing b.tier(rt) live-tier read (the +whole:Route site) and passes it to spawnInCgroupAtTier, which previously made the same read itself. Inside the build closure (which the cgroup manager calls after writing the limits) it asks cgroup.Manager.Capped(host, child, tier), a read of memory.max in the agent's own delegated cgroup subtree, and only when that reads back as the tier adds GOMEMLIMIT=GoMemLimitOf(tier.MemoryMax) to the child env, unless the app's fileEnv names it. No delegation, a cgroup that could not be made, or a failed memory.max write gives no default (Astra R1 P2-1). Containment behaviour unchanged; no gate moved or weakened; no registry, /data, release or store read added.;rev3=census-ruling-platform-mail-submission;basis=Task 4: the inline mount (Timers, UpdatesReader) is replaced by b.controlMount(rt, tokenReader, n): the same verbs under the same conditions, plus the mail verb when b.Mail is set. The three rt.Host reads move into controlMount; the route is passed whole. Agent, not root; nothing else changes. Task 6: also calls warnUndeclaredMailBuild with the route and the version being spawned (a log line and an instance event, never a refusal). file:Command@11633,registry:Host@13029,registry:Host@13390,registry:Host@13484,registry:Host@258,registry:Host@4236,registry:Stateless@11564,whole:Route@11456,whole:Route@11605,whole:Route@12126,whole:Route@13781,whole:Route@13873,whole:Route@1527,whole:Route@189,whole:Route@1944,whole:Route@2305,whole:Route@287,whole:Route@4091,whole:Route@4119,whole:Route@4430,whole:Route@476,whole:Route@6501,whole:Route@7027,whole:Route@9259,whole:Route@9383,whole:Route@9432 3d41b02bd489afc873fb9b89d214dc338348aea37fb3de8a138dc26cde6b69ad
internal/activator/backend_exec.go ExecBackend.spawnUnitFrom legacy accepted-legacy accepted-legacy;rev3=census-ruling-carlos-run;basis=Re-digested at the pre-land merge: the body includes main's own change under census ruling 292, with no further change from this branch. the agent (/opt/carlos/carlos agent, carlos-edge.service, user carlos): main's body; it calls prepareKeyedAt and keeps the launch environment and its key layer on the generation's handle; read sites unchanged, offsets moved;rev3=census-ruling-wake-latency-2;basis=times the launch's steps with time.Now() (build, prepare, launch file, gate, root start) and adds them to its existing "started" journal line; no read added or moved;rev3=census-ruling-rootfs-apps-2;basis=the unit names in its error and log lines go through runUnitName, and newUnitProcFor's new error (a role with no unit to observe) fails the start as markStartUncertain after root started the unit; the binary spawn is otherwise unchanged, a rootfs row never reaches it (nestedGate refuses one); no read added;rev3=census-ruling-stateless-replicas-1;basis=Task 3a: Use the verified generation/launch mode to remove CARLOS_DB after environment merges and omit the binary --db argument where applicable. Existing runtime, layout, secrets and exec gates remain; route reads are mode projection only.;rev3=census-ruling-edge-page-cache-1;basis=computes the page cache launch inputs once (launchInputs: sha256 over the staged or pinned exe's Version and the fileEnv this spawn already read; "" with no exe, since root binds the movable live link) and keeps them on the unit handle (up.inputs); no new file, registry or bucket read; read sites unchanged (29); no read added;rev3=census-ruling-gvisor-demos;basis=Task 5: gate launch using startup-captured mode and existing route/role/layout before preparation or execution; migrate structured root start identity and reject mismatches. Unsupported gVisor paths refuse; native behavior and existing root authority checks retained. No new root read source. Merge2 e8a1ddde: retain main launchInputs computed from the captured file environment and pinned/staged build and store them on the handle, alongside branch sandbox gate, validated root StartResponse Unit/Sandbox/InvocationID and all uncertain-start cleanup. No new direct read.;rev3=census-ruling-fix-silent-start-kill-861;basis=#861: one log line before killFailedGen naming the host, the generation unit (runUnitName) and the error already in hand; the +registry:Host sites are those two arguments to log.Printf; no new read source, behaviour unchanged;rev3=census-ruling-instance-gomemlimit-991;basis=#991: the agent as carlos (nested start): resolves the zero tier once (b.tier(rt), the existing live-tier read), adds GOMEMLIMIT=GoMemLimitOf(tier.MemoryMax) to the launch file env unless the app's fileEnv already names it (withGoMemLimit; skipped under gVisor, where root supplies its own and drops any launch value), passes that same tier to startRole, and logs it. No new read source; root still validates memory_max against the size table; read sites unchanged.;rev3=census-ruling-platform-mail-submission;basis=Task 6: calls warnUndeclaredMailBuild with the route and the version being spawned. Logs and emits an instance event once per (host, version) when the app is switched and the staged manifest does not declare --mail submit; never refuses. Agent, not root. registry:Host@1308,registry:Host@2277,registry:Host@2382,registry:Host@2513,registry:Host@2970,registry:Host@4046,registry:Host@4407,registry:Host@5175,registry:Host@5761,registry:Host@6026,registry:Host@6183,registry:Host@6204,registry:Host@6425,registry:Host@6610,registry:Host@7005,registry:Host@7266,registry:Host@7375,registry:Host@8374,registry:Host@8468,registry:Stateless@2327,whole:Route@1093,whole:Route@1472,whole:Route@1714,whole:Route@197,whole:Route@2127,whole:Route@2367,whole:Route@3027,whole:Route@3082,whole:Route@4282,whole:Route@431,whole:Route@6258,whole:Route@7455,whole:Route@995 ddbf6eef60b08fca97a3b63af8a931efb73e014392059996073d41811b488493
internal/activator/prepare.go ExecBackend.listenControl legacy accepted-legacy accepted-legacy;rev3=J1;basis=root-route;rev3=census-ruling-edge-page-cache-1;basis=passes the whole route to edge.ListenControl instead of rt.Host (the -registry:Host +whole:Route change); nothing else;rev3=census-ruling-platform-mail-submission;basis=Task 4: the same replacement as spawnChildFrom, with gen as the write fence's generation, so the nested and rootfs listener mounts exactly what the flat one does. Agent, not root. registry:Host@508,whole:Route@361,whole:Route@389 f6534861cdbeef80dbcfaf6b07df685e4ac2f2a86650db54f174871526a50aff
internal/activator/rootfs.go ExecBackend.spawnRootfs legacy accepted-legacy accepted-legacy;rev3=census-ruling-rootfs-apps-2;identity=the agent (/opt/carlos/carlos agent, carlos-edge.service, user carlos);basis=root-route (J1, as spawnUnitFrom, whose shape it has): new (rootfs Plan 2 Tasks 5 and 9): prepareKeyedAt (the instance's own directories, environment and listeners, unchanged), the schema-2 tenant launch file (environment only, CARLOS_SOCKET and CARLOS_DB set by the agent), the caller's exec gate, then StartRootfs over the control socket naming the image and web; root resolves the command from its own staged manifest (C4) and the tenant file may name no command (the trampoline refuses one); the failure handling is spawnUnitFrom's; its sites are the row's host and route; no root decision; final fix I1: root's answers that guarantee no start (ErrStartRefused: 503 not ready or claim-armed, 501 unconfigured, 400, 409, 507), like its 403, are marked a refusal (refuseRootfs), so verdictOf and classifyStep record no failure of the build and no stop is asked; a 502 and a transport failure still may have run; the same nineteen sites, offsets moved;rev3=census-ruling-rootfs-apps-3;basis=rootfs Plan 3 fix wave 1 (d35fcb1f, census P1-1): takes the tier root is asked for as an argument; a zero tier means GenTier's (the former body), so a caller that chose a limit has it kept, as spawnChildFrom and spawnUnitFrom keep theirs; the same nineteen sites, no read added;rev3=census-ruling-stateless-replicas-1;basis=Task 3a: Use the verified generation/launch mode to remove CARLOS_DB after environment merges and omit the binary --db argument where applicable. Existing runtime, layout, secrets and exec gates remain; route reads are mode projection only.;rev3=census-ruling-edge-page-cache-1;basis=sets up.inputs = launchInputs(id.Version, fileEnv): the image version and env this spawn already read, hashed in memory; no new read; read sites unchanged (20); no read added;rev3=census-ruling-gvisor-demos;basis=Task 5: gate launch using startup-captured mode and existing route/role/layout before preparation or execution; migrate structured root start identity and reject mismatches. Unsupported gVisor paths refuse; native behavior and existing root authority checks retained. No new root read source. Merge2 e8a1ddde: retain main launchInputs on rootfs handle from existing staged image version and fileEnv. Keep branch sandbox gate and root identity validation. No new read.;rev3=census-ruling-fix-silent-start-kill-861;basis=#861: one log line before killFailedRootfsGen naming the host, the unit and the error already in hand; the +registry:Host site is that argument to log.Printf; no new read source, behaviour unchanged;rev3=census-ruling-platform-mail-submission;basis=Task 6: the same warnUndeclaredMailBuild call for a rootfs spawn. Agent, not root. registry:Host@1358,registry:Host@1531,registry:Host@1831,registry:Host@1950,registry:Host@2697,registry:Host@3034,registry:Host@3261,registry:Host@3388,registry:Host@3713,registry:Host@3841,registry:Host@390,registry:Host@3950,registry:Host@4667,registry:Host@4761,whole:Route@1105,whole:Route@1137,whole:Route@1224,whole:Route@199,whole:Route@2057,whole:Route@3094,whole:Route@4026,whole:Route@502,whole:Route@602,whole:Route@732 a19e5be10a746fec3fedc5715314f6cf00fa6f3d4be23db3242bf2f599a1a563
internal/host/agent.go runAgent authority B,C,D,F rev3=census-ruling-self-serve-moves-1;basis=the agent (/opt/carlos/carlos agent, carlos-edge.service, user carlos): builds the box's lifetime judge once (newBoxJudge, nil with host claims on) and hands it to the seed placement, the moves and runs workers and every loop it starts; read sites unchanged, offsets moved; B,C,D,F authority retained; self-serve moves 1 Task 8: derives the box's lifetimes switch from the judge once (lifetimes := boxJudge != nil) and hands it to the edges file loop; read sites unchanged, offsets moved;rev3=census-ruling-plans-4d-lapse;basis=arms two more plans hooks from the same snapshot: e.SetPlanDisabledFor(planDisabledFor) beside SetPlanGovernedFor, and svc.SetDisabledFor(planDisabledRoute) beside SetMaxRunFor (plans 4d); the reads live in those units (plans-4d-units decision); read sites unchanged, offsets moved;rev3=census-ruling-rootfs-apps-2;basis=main's body as of the merge of origin/main 9b81d97b (with main's plan rate ceiling, edge request records, regional box names, self-serve moves plan 1, plans 4d-1 lapse and its other later changes under main's own census rulings) plus the rootfs placement wiring in the activator start: an agentRootfs built from eb.NestedOK, CARLOS_DEPLOYMENT_SINGLE_TENANT, CARLOS_POOLS, the claim flag, swapArming's answer, the control client's /ready/rootfs and, on a fleet box whose identity resolved, fleetOwnerCheck over the deploy store main already opens for the fleet label (fleetStore), then arm and armedRootfs.Store; this body reads nothing new itself; the closures it wires read later, at a rootfs wake and each status tick: GET /ready/rootfs over the control socket, NestedOK's checks, and release.FleetOwnerKey for the judged row's own account and this box's fleet from the deploy store;rev3=census-ruling-instance-egress-sizes-328-329;basis=#328 plan 2 Tasks 7 and 11, #329 plan 3 Task 7 and plan 1 Task 7's policy cache: the control client is built once and handed to eb.Control, to the status tick (egressStatus) and to a new egressNudgeLoop goroutine; armSizeSource(svc, "/sys/fs/cgroup") after the activator Service; armPolicyCache() after armChangeIndex; statusLoop takes egressStatus. The reads are those units' own (decision rows); this body reads nothing new: the same five sites, offsets moved, in the agent; B,C,D,F authority retained.;rev3=census-ruling-remote-instance-metrics;basis=builds the metrics loop's owners closure (metricsOwners over the agent's registry, the activator and cgm.Leftover) when an activator exists and hands it to metricsLoop; reads nothing new itself;rev3=census-ruling-edge-asset-cache-3;basis=adds file:Statfs. runAgent keeps its authority (B,C,D,F). The new site is assetcache.Statfs, an exported assetcache.FS interface value (var Statfs FS = statfsFS{}), not a function value and not a call in runAgent: the ready hook passes it to armEdgeAssetCache as the store's filesystem, and armEdgeAssetCache calls its Space method on the configured data directory (dataDir(): $CARLOS_DATA_DIR, else /data), which calls unix.Statfs there (statfsFS.Space, accepted legacy at census-ruling-edge-asset-cache-2). No request-supplied pathname reaches it.;rev3=census-ruling-remote-metrics-nested;basis=main's body (merged origin/main acfa4f80, under main's own census rulings) plus: snapshots the nested layout (snapshotNestedUnits over /sys/fs/cgroup/carlos.slice/carlos-instances.slice) once at start, before the activator, and hands the metrics loop a unitSources struct (stamped units, routeHostNames, that root and the snapshot); reads nothing new itself;rev3=census-ruling-region-ha-p1a;basis=the agent (/opt/carlos/carlos agent, carlos-edge.service, user carlos): wires region HA P1a into the activator: cfg.Record = haRecordFacts(openDeployStore, boxJudge) (the box's lifetime judge this body already builds with newBoxJudge, nil with host claims on; CI fix) and cfg.Self = lease.CurrentSelf; eb.Lifetimes (the process's lifetime index), eb.Registry, eb.StartupSwept (seedSweptAtStart.Load), eb.FilesStore from newProductionFilesStore (now lease.NewFilesStore, rootaws-loaded, a log line on failure) and lease.SetObligationDir(<data>/.ha-owed) (logged on failure; HA acquires then refuse); this body reads nothing new itself, the same five sites; the reads are those units' own (haRecordFacts and lease's SetObligationDir are new rows on this card); merge of origin/main d7ae1d76: main's own later changes to this body are kept as main has them, under main's rulings (census-ruling-remote-instance-metrics: the metricsOwners closure for metricsLoop; census-ruling-edge-asset-cache-3: the +file:Statfs site, assetcache.Statfs handed to the asset ready hook); this branch's change is the same as above;rev3=census-ruling-region-ha-p1b1;basis=region HA P1b-1: builds one termfence.Confirmer (Self from lease.CurrentSelf at each call, EC2 DescribeInstances method only, client from rootaws.LoadDefaultConfig with retries off, built lazily on first use) and sets eb.OwnerTerminated; this body reads nothing new itself, the same six sites;rev3=census-ruling-rootfs-apps-3;basis=rootfs Plan 3 Task 7: the startup Sweep literal hands its answer to startupSwept, which logs as before and, only on a clean sweep, marks rootfs admission swept (MarkRootfsSwept); same Sweep call, no read added;rev3=census-ruling-managed-fleets-1b;basis=managed fleets 1b (controller ruling after branch review R1, and Paul's R2 ruling): sets svc.Fleet = fleetWakeFor(os.Getenv, identity, identErr, fleetStore) from the identity it already resolves once and the deployment store the fleet loops already opened, and logs an ERROR naming the identity error when the box is on a fleet with an invalid identity. fleetWakeFor reads CARLOS_REGION and CARLOS_FLEET from the same environment. Read sites unchanged (6). Agent, not root; a platform box is unchanged.;rev3=census-ruling-rootfs-apps-6;basis=rootfs Plan 6 Task 12: one call more beside armRunsPass, armInteractivePass(svc, reg, rolloutSink, boxJudge), in the same activator Configure hook, handing it the same box judge; fix round 1 (Astra P2, shutdown): after svc.Shutdown(ctx), shutdownInteractive(ctx) ends and joins every interactive session under the same shutdown budget; the worker's own reads are its units' (interactive.go); this body reads nothing new, the same six sites; merge of origin/main 6f1f6ca6: main's svc.Fleet = fleetWakeFor(...) and its invalid-identity ERROR line are kept as main has them (census-ruling-managed-fleets-1b); this branch's change is the same as above; read sites unchanged (6);rev3=census-ruling-fix-set-aside-exdev;basis=set-aside EXDEV fix: one field more on the agent ExecBackend literal, RawInstanceDir: layout.RawInstanceDir (a pure path join: <dataDir>/.instances/<InstanceID(host)>), so the start rule set-aside moves a copy out through the raw directory instead of through the nosymfollow bind; this body reads nothing new, the same six sites;rev3=census-ruling-durability-3a-escrow;basis=durability 3a Task 3: one more assignment beside eb.FilesStore: eb.EscrowKey = haEscrowKey(os.Getenv("CARLOS_SECRETS_KEY")), the agent's own environment parsed by appconfig.ParsePrivateKey as the moves pass parses it (unset or unparseable: a log line and nil, and HA publication refuses on the box). No path is opened or read, no read site added; the same six sites, offsets moved; B,C,D,F authority retained. Durability 3a Task 4: one more goroutine beside configSyncLoop: go escrowLoop(agentCtx, reg, svc), the escrow sweep every 30 s over the same registry and Service. This body reads nothing new itself; the same six sites, offsets moved; B,C,D,F authority retained. Durability 3a Task 5: one more call beside eb.EscrowKey: wireRawSecretPages(eb, PageOperator, metricsBoxLabel(os.Getenv, readMachineID())), which sets eb.OnRawSecret to page an operator (alerting.Page through PageOperator, LevelIncident) on its own goroutine with a 20 s timeout; metricsBoxLabel and readMachineID are the reads this body already makes for the moves refusal log; no new read site; the same six sites, offsets moved; B,C,D,F authority retained. Merge of origin/main 90c4d3aa: main's own later changes to this body are kept as main has them, under main's rulings; this branch's change is the same as above. Merge of origin/main 00bf5b8c (fleet set-aside EXDEV fix): main's change to this body is kept as main has it, under its own census ruling; this branch's change is unchanged.;rev3=census-ruling-probe-burst-limit;basis=two more sink wirings beside setAnalyticsSink: setProtectionSink(e.SetProtectionRecordOnly) and setAssetOwnersSource(e.AssetOwners), function values the telemetry pass calls; this body reads nothing new, the same six sites; authority B,C,D,F retained; no new root read or write kind;rev3=census-ruling-region-ha-p1b3a;basis=Arm HA placement exactly once on the existing Service before activatorStart and edges publication, wiring AwakeApps and the PageOperator callback; existing six read sites unchanged, no new root authority.;rev3=census-ruling-stateless-replicas-1;basis=Final review I3: start the concrete coordinator's renewal worker with agent setup; existing closeReplicaCoordinator shutdown cancels and joins it before release. No new read sites or credentials. Merge origin/main c59715e7: retain main's armHAPlacement(svc, PageOperator) wiring beside the existing activator setup; stateless coordinator and shutdown wiring remain. Same read sites; no new root read or credential.;rev3=census-ruling-edge-held-streams;basis=the agent (/opt/carlos/carlos agent, carlos-edge.service, user carlos): in the edge-ready callback, calls act.SetHeldWakeHook(e.HeldWake) when act is non-nil (installing the non-blocking wake callback) and stores e.HeldStreamsForStatus in heldStreamsSource. Wiring of in-memory callbacks only; no read added.;rev3=census-ruling-region-ha-p1b3b-t;basis=Wire Service.SetDutyView to the live edge DutySnapshot in the ready callback. No new read; no new loop or cloud operation. B2 wires the registry as the persistent DutyStore before service startup; no new cloud or filesystem path. B3b: arm one journal-backed termination consumer before service startup using agentCtx and the shared confirmer; expose edge tick and join at edge shutdown. No new direct read sites.;rev3=census-ruling-agent-start-demo-1;basis=Passes the existing registry, data store and hibernation prefix into the demo worker, and the existing instance-control client into the demo before-exec hook. No alternate data store or polling loop. Merge resolution against origin/main 9bd45488 retains main's HA departure controller, lifecycle and duty wiring alongside the demo data store and worker; no read site added by the resolution.;rev3=census-ruling-region-ha-p3a;basis=P3a Task 3: install closed fixed admission before every launch source, bind activator/backend and edge, wire the real termination Started lifecycle and role reader after the change index; close before cancellation/child shutdown. No new external reads or cloud authority. Fix R1: move bind/lifecycle/edge-option wiring into wireAgentAdmission and worker listing into runWorkerBootPassAfterAdmission. Worker boot waits for admission before listing then uses unchanged bounded wakes and per-host serialization; whole Route read moves to the helper. No new storage, cloud, or root execution authority. Preserve merged main's agent wiring and census basis; the branch removes one whole Route use by moving worker iteration to the helper, with no added read kind.;rev3=census-ruling-stateless-replicas-2;basis=Slice 3b: arms a fleet-only worker using the existing registry, activator, backend and authenticated console transport. Owned worker stops and joins at shutdown. No new bucket reader. merge of origin/main 9b8b2c50: retain HA duty/departure lifecycle, wake-slot and existing agent wiring alongside the replica placement worker; no new read introduced by resolution. merge of origin/main 6be08467: Retain main demo configuration, admission, build and expiry wiring alongside the replica worker; merge-only body change, no additional read. merge of origin/main 7920cccf: Retain main box-role/group admission wiring and boot publication beside the owned replica worker and shutdown; main moves the boot registry List into runWorkerBootPassAfterAdmission, removing its inline whole Route site. No new read introduced by conflict resolution.;rev3=census-ruling-stateless-replicas-3;basis=Task 1 fix round 1 M3: retain the private snapshot source and cancel/join ownership, but use the replica-health-specific retry loop. It logs its first failure only and retains the existing exponential backoff capped at 30 seconds; unsupported builds return nil. Existing five direct read sites unchanged; no new credentials, bucket reader or app lifecycle action. Fix round 1 Q20: publish Edge.ReplicaSnapshots as a separate in-memory status source, leaving the tenant-visible Upstreams source unchanged. No new external reader or authority.;rev3=census-ruling-region-ha-p3b;basis=Load root-written group marker/configuration, configure signed boot binding and agent receipt completer, wire cancellable admission into departure work and expose cached GroupReaderSnapshot. New indirect boot reads use protected root files; agent-owned receipt controls duplicate initial completion only, never root restart permission. Same five direct sites. Merge 45cebde4 retains the replica health socket lifecycle and setReplicaSource beside GroupReaderSnapshot; no extra read beyond main.;rev3=census-ruling-agent-start-demo-2;basis=agent.go:309-329 opens demo-traffic.db beside the operator-configured registry when a demo domain exists, closes it at shutdown and wires drain-before-purge; :1010-1019 shares the worker and write gate; :1164-1177 installs the fleet identity and closed-until-worker serving callback. One added whole Route pass; the new indirect filesystem/SQL reads are claimed in openDemoTraffic and worker/store units. No request chooses the database pathname.;rev3=census-ruling-region-ha-p1b3b-s;basis=Wire the service duty view to authoritative cached sidecar manifest placement in LifetimeIndex and the edge sidecar projection; missing policy denies duty. Existing instance duty wiring remains.;rev3=census-ruling-region-ha-g2-t3;basis=T3a: wire eb.Page = PageOperator beside OwnerTerminated before departures arm, so suspect-holder pages work if departure setup fails; no new read; existing nine sites and authority unchanged; pages through the existing sink. T3b: publish the same backend through an atomic pointer for the metrics observer, and clear it on return; no new external read or authority.;rev3=census-ruling-agent-start-demo-3;basis=Wire the claim activator and root snapshot client into the demo worker; pass moved readiness to status reporting. Census read-site delta: unchanged (9).;rev3=census-ruling-region-ha-g2-fixes;basis=Wire local pool evidence, live withdrawal activator, startup ingress scan and alias publication, and edge lookup; no new direct sites; new indirect record/claim reads use existing store/judge paths described in ingress helpers.;rev3=census-ruling-region-ha-g2r-fixes;basis=W3: starts the existing record-view backstop loop with a departure-inventory listener (non-blocking, coalesced signal) even without an armed RecordView; it requests the existing full pass (backstopFullDue) there. Same nine read sites; no new read or authority.;rev3=census-ruling-region-ha-graceful-terminate-t2;basis=Derive one signal-time deadline with a 90-second budget; cap departure stop and startup/seed/service shutdown joins by it. No read added.;rev3=census-ruling-static-sweep-periodic;basis=in the edge-ready callback, publishes e.LargestStaticTree in staticTreeSource for the disk alert line (diskAlertFrac in the metrics loop); in-memory wiring only, no read added; read sites unchanged (9);rev3=census-ruling-edge-page-cache-1;basis=wires the exec backend's CurrentInputs into the edge cache (wireCurrentInputs) and, in the ready hook after armEdgeAssetCache (whose returned store it now keeps), calls armEdgePageCache, which does nothing unless CARLOS_PAGE_CACHE=1; read sites unchanged (9); no read added;rev3=census-ruling-gvisor-demos;basis=Capture sandbox resolution and refusal once; log errors once; gate route admission and BeforeExec before process launch. No new root read. Task 5: pass the once-captured sandbox effective mode/config error into ExecBackend, UnitBackend and the immutable Client expectation. Same startup environment/registry reads; swapArming declines gVisor before placement. Task 8: arm read-only status projection with the existing Client.SandboxStatus callback. Agent status now queries the existing root /ready endpoint; no new root authority or guest-file input. Merge2 e8a1ddde: retain main wireCurrentInputs and armEdgePageCache through the existing asset-store ready hook alongside branch once-captured sandbox mode, wake gates and root status wiring. No new direct read; main page-cache helpers retain their own census overlays.;rev3=census-ruling-region-ha-held-build;basis=wires the drain state: svc.SetDrainingSource(boxDrain.IsDraining), svc.SetPeerDrainView(e.PeerDraining), e.SetPeerDrainedHook(svc.DropHoldersNaming); in-memory only; no read added; region HA held-requests Task 5: on group members, starts the drain driver over the activator, the edge and boxDrain, and serves its root-only drain socket; no read added beyond the socket's own Branch review r1: the drain state follows the root start fence on group members (the fence reader is the existing fenceLocation.read, a root-owned fixed path); e.SetPeerUndrainedHook(svc.AllowHoldersNaming) beside the drained hook (memory only); the drain socket serves only the agent's own user. No read added.;rev3=census-ruling-security-review-mitigations;basis=Wire the cached operator flat-layout choice into the exec backend's new-resident refusal; no read source added, existing authority retained.;rev3=census-ruling-w6-ingress-drain;basis=agent (user carlos), not root. Builds the ingress drain (newIngressDrain) with arming read at ask time from os.Getenv (CARLOS_REGION_HA, CARLOS_INGRESS_TARGET_GROUPS, both from the root-owned host.env), the fixed admission and lease.CurrentSelf (existing IMDS identity); its reader is awstg.Load, the box role's credentials calling ELB DescribeTargetHealth/DescribeTargetGroupAttributes (new AWS reads, by the agent). Wires admission.closeStartsForIngressDrain, the lbhealth drain condition, ingress.setEdge, and ingress.shutdownStarted in WithShutdownStarted. The drain socket (/run/carlos/.ha-drain/drain.sock, agent-user only, existing) is now also served on a fixed box with the drain configured (was group members only), routing /v1/ingress/* to the ingress drain and the group drain verbs to 404 there. armHADepartures now takes fixtureDepartureGetenv() and MakeQueue fixtureDepartureQueue(), which in a production (non-rootrunner) build are os.Getenv and nil, as before. Read sites unchanged (9).;rev3=census-ruling-stateless-replicas-4-task1;basis=Arms the fleet-only replica swap worker next to the placement worker: same console URL and fleet token as the existing replicaCoordinatorAPI, the existing activator Service; stops and joins at shutdown. No new read site, credential or bucket reader.;rev3=census-ruling-stateless-replicas-4-task2;basis=Task 2: sets deployWorker.step to the rollout scheduler answer for the record permit (replicaStepOf over armedRollout), an in-memory callback; no read site, credential or bucket reader added.;rev3=census-ruling-stateless-replicas-4-task2-fix2;basis=Task 2 fix round 2: the swap worker step is armedReplicaStep, the same lazy scheduler lookup as before as a named function; no read site added.;rev3=census-ruling-stateless-replicas-4-merge-main;basis=Merge of main 5fac2ff1: both sides changed it. Main (01d6ca78, linked-deployments-slice1) starts linkLoop beside tunnelLoop; this branch keeps its replica coordinator wiring. Both kept as-is; no read added.;rev3=census-ruling-stateless-replicas-4-final;basis=#511 final wave item 2: wires the swap worker's drive (armedReplicaDrive, the armed rollout manager's DriveReplicaRelease); no read added;rev3=census-ruling-stateless-replicas-4-merge-main2;basis=Merge of main af871da0 (v0.34.49): both sides changed it. Main (178dcfe5, member-backups-2a) moves the inline duty-view closure into armDutyView/dutyView and starts verifyAssignLoop; its sites drop by registry:Host and whole:Route x2 as main recorded them. This branch keeps its replica coordinator, swap worker and drive wiring. Both kept as-is; no read added.;rev3=census-ruling-stateless-replicas-4-drill3;basis=drill 3 R24: makes one in-memory channel, closes it (once) inside the edge's existing shutdown-started callback after ingress.shutdownStarted, and passes it to tunnelLoop, which drains only a fleet channel name; no read added, same six sites; touches no admission, lease, ingress drain, listener or file; the agent process, no root decision;rev3=census-ruling-edge-ppv2;basis=Agent (uid carlos), not root. memwatchLoop now gets edgeProxyCounters(&demoEdge) (in-process counters, no read). The drain socket's driver is newAgentDrainSocket(ingress, e, os.Getenv), which attaches the edge trust handler only when CARLOS_INGRESS_PROXY_SOURCES in the agent's environment (from the root-owned host.env) parses to a non-empty list; the socket is served when drainSocketServed: a group member or a configured ingress drain (both as before), or a box armed for PROXY protocol (new). The socket's path and agent-user-only permissions are unchanged. Read sites unchanged (6).;rev3=census-ruling-same-box-edge-fence;basis=Agent (uid carlos), not root. One added line: armEdgeFenceStatus(ctl.EdgeFence), beside the existing armExecSandboxStatus, so the layout report can ask root's /ready for the edge fence state over the control socket client the agent already holds. No read added.;rev3=census-ruling-platform-mail-submission;basis=Task 4: sets eb.Mail = mailsubmit.SocketForwarder{} on every box, and eb.MailSwitch to a mailSwitchCache's On that opens the deploy store itself through openDeployStore, retried at most once a minute with an error line until it opens (review round 1, Task 4 P3), armed for the serial-move refresh (armedMailSwitch). Task 6: also sets the ExecBackend's ManifestOf, the same staged-manifest read as TierOf (rt.App and RouteAccount(rt), hence +registry:App and +whole:Route), for the spawn-time check of decision 10, which logs and emits an event and never refuses. Agent, not root. file:Exec@21578,file:Open@2191,file:Statfs@57102,registry:App@13287,registry:App@13665,whole:Route@13279,whole:Route@13657,whole:Route@50580 ee6470495a59bc35232da4558dc1082c7c068dbee1893cf3c2da365557b9360b
-@coverage . 564f9e13ca4d48a3bbcb4da387e9ec667f2c9f9a61265012868ab83e15d4f376
+@coverage . 295f50675373126c17b6adc286bad9a8935f6e1020fca5daa1ad23f71b6f27db
@coverage infra/modules/region-host d1a978ca67367880d0940ae7aa460f311addd4335c196a279d86caa6fe1e1721
@coverage infra/modules/region-host/tests 1aa5c549b79e7d8b19a266a2aeae8e4e2bb22b40072f36362da95bcf2c439a07
-@coverage internal/activator 363791080ce7f92df7d2090181ead6c4a611a0fd449f82384aef56fbb790732e
+@coverage internal/activator 583441b86d19dc592f5275a310fd7b5983c6f970766fed9f3ab7de202812dcb5
@coverage internal/host 747db9767698d63c8604bdc001a0423eebdd818e618eb2baad52324b1e0e7ac0
@coverage internal/host/demo_units 3a34238356068c6176879f3ee189c81af8e08bfcc0246c5feba80d7169f7af6a
-@coverage internal/host/units 63a333f0bb4a354fdde9802089f4ec6794cdfbf774c20fbd48cffab805cd022c
+@coverage internal/host/units 1c742096c3a89946d8539b0113ea2ce07a833356d4a0262e55f8d5defb566055
@coverage internal/hostenv ba3d0f9a72e3a494116ce3ace34b05ab7218422327c365d57d2c6aabaa252558
@coverage internal/instancectl 811493ad636a21f5f8e7f2336e8e58055fd2a83f53dd71ef689cd90232e7d3df
-@coverage internal/mailer 5abe7e693556a59a6e3e2e74dbabc4204a17060f3be02eb0acdb32d90d248146
-@coverage internal/mailsubmit 519123e15891e0802427595306d8caca1fd7f4f861ae1a2ec70e1c10f012e263
+@coverage internal/mailer 2f3d74f7801327b2cfd4c64b5cec19777b6db5e2ec3f3b657b15a5da0c870e9b
+@coverage internal/mailsubmit 6e97704229c65015f2ae0f2f8c5fcc10d1dc470491161a23d04098290ea9cdfb
@coverage internal/mailwire 0242392c670a0f61b875056b0d79576ccb69c2e29f56735cbb191e7d038222a0
@coverage internal/moves 9390702695d308a327f5572f4ff5967718141c5d385dff7671ff1e2c825ef407
@coverage internal/provision a7fca446b2464e9d0804272a46146013085cdec8fecb96a3508cc055295f31d3