Skip to content

plugin-audit + objectql lifecycle: build the audit tamper-evidence ADR — sealer, signed checkpoints, redaction and expiry amendments, os audit verify #31908

Open
1 of 1 issue completed

Description

@objectstack-fleet

repo:cloud#3 · os-warren · session_01JQwxbZqfEd7pcckjz3pGqn

Filing gate: ③ a task on the maintainer's word. The maintainer ruled (c) on cloud#4016 at 2026-11-09 11:30Z: stage 1 is in the framework. This card builds what the ADR card filed with it decides. Blocked until that ADR merges.

Cloud consumer: objectstack-ai/cloud#4016 (Enterprise stage 2 reads these checkpoints).

维护者速读

  • 问题:同上一张 ADR 卡,审计日志被改被删时证明不了。
  • 要做:按 ADR 实现封存器、检查点对象、脱敏和到期删除的修正记录、到期删除按检查点整块删除,以及 os audit verify。
  • 需要你做的:无。ADR 合并前本卡保持阻塞。

Work

Implement the ADR in plugin-audit (canonical form, sealer, checkpoint object, amendments, verify command) and in objectql's lifecycle (prune aligned to whole checkpoints, with an expiry amendment). The design doc's §2.4 sets the cost bar: nothing on the insert path, about 20 µs per row to seal, 27 ms per 10,000-row checkpoint. A synchronous chain head cut throughput 13.8× at 8 writers per organization, so the sealer must stay asynchronous.

Done when

On a real kernel with the archive datasource, os audit verify reports:

  • a row edited through the system context as modified;
  • a deleted row as missing;
  • a redacted row as redacted, with its amendment;
  • a pruned window as expired by policy.

It reports an untouched window as unmodified, across the hot-to-archive move.

Who acts

The server lane, after the ADR merges.

Dedupe: as on the ADR card.

Related: cloud#4016, cloud PR #4025.

Sub-issues

Sub-issues

1 of 1 Issues completed
Loading 1 sub-issues

Activity

  1. added
    enhancement
    priority:p2
    domain:server
    on Nov 9, 2026
  2. objectstack-fleet commented on Nov 9, 2026

    @objectstack-fleet
    ContributorAuthor

    triage#1 · os-zhuang · session_01AavokzJ5DndAwitDXvKy4U

    Path: none

    Triage: p2 · pm:on-hold · waits on the maintainer's cloud#3823 call · 2026-11-09T12:01Z

    ⛔ Not a claim.


    Generated by Claude Code

  3. added
    pm:on-hold
    on Nov 9, 2026
  4. objectstack-fleet commented on Nov 9, 2026

    @objectstack-fleet
    ContributorAuthor

    triage#1 · os-zhuang · session_01AavokzJ5DndAwitDXvKy4U

    Path: none

    Triage: hold lifted → pm:queue · domain:server · p2 · 2026-11-09T23:59Z

    ⛔ Not a claim.


    Generated by Claude Code

  5. added
    pm:queue
    and removed
    pm:on-hold
    on Nov 10, 2026
  6. objectstack-fleet commented on Nov 10, 2026

    @objectstack-fleet
    ContributorAuthor

    domain:server#4 · os-steve · session_01ADHkmP8JJo4zF2sjTBRwnX

    Claim: PM loop round 14 · #31908 · 2026-11-10T04:56Z
    Session: session_01ADHkmP8JJo4zF2sjTBRwnX (seat); dev = card thread session_01ADHkmR91XAgACaLbYX476P
    Account: os-steve
    Branch: claude/project-thread-vs4lnh
    Worktree: the card thread's checkout of objectstack-ai/objectstack
    Domain: domain:server
    Seat: domain:server#4
    File surface (provisional; Step 0 fixes it per slice and the seat amends this claim): packages/plugins/plugin-audit/** (canonical form, sealer, the three new objects, signer, amendment writer, the three migrations, AUDIT_EXCLUDED_OBJECTS), packages/objectql/src/lifecycle/** (the expiry seam beside registerReapGuard), packages/cli/** (os audit verify), and in packages/spec only src/data/object.zod.ts (lifecycle.seal and its authoring refusals), src/contracts/crypto-provider.ts (the audit_seal scope) and the two seam contracts, with their regenerated references and docs; root .changeset/. Never docs/adr/** (stop on breach)
    Container & model: L, mode:thread, model: default tier, effort: high
    Clause-②: yes (narrowing) (provisional: P1 widens the object schema with lifecycle.seal and refuses three lifecycle policies beside it at authoring; Step 0 re-reads each slice against scripts/pm/clause2-line.mjs and amends through the seat)
    Metadata-protocol: added (P1: the authorable lifecycle.seal key; @objectstack/spec minor)
    Responsibility: build ADR-0154 (adopted 2026-11-10, 6e766012f5) D1–D11 in four serial PRs from one thread: P1 sealing core (spec key with its reader as an ADR-0049 pair), P2 os audit verify, P3 redaction amendments, P4 expiry amendments (Fixes #31908) · today nothing can prove the audit log was not changed or deleted · read by Enterprise stage 2 (cloud#4128)
    Thread-read: none
    Premise: holds. ADR-0154 is on main; the ADR card #31907 is closed (landing note 6759357073).
    Serial constraints: P1 → P2 → P3 → P4 on this seat. New public names beyond ADR-0154's table are nominated in Step 0 and ruled by the seat before code.

  7. objectstack-fleet commented on Nov 10, 2026

    @objectstack-fleet
    ContributorAuthor

    domain:server#4 · os-steve · session_01ADHkmP8JJo4zF2sjTBRwnX

    Claim amendment · #31908 · 2026-11-10T05:04Z · amends claim 6759393778 · slice plan, File surface, Clause-② and Metadata-protocol for slice P1a (Branch claude/project-thread-vs4lnh unchanged)

    Seat rulings on Step 0:

    • Five serial slices on this branch's thread, one PR each: P1a pure core, P1b lifecycle.seal with signer and sealer, P2 os audit verify, P3 redaction amendments, P4 expiry amendments. The default lifecycle.seal on sys_audit_log lands in P4, so no release between slices holds sealed rows that a later slice would read as modified or missing. P1a–P3 say Part of #31908; P4 says Fixes #31908. Each slice stays at or under 3000 lines.
    • Spec carrier: the three packages/spec additions ride on this card. ADR-0154 D2, D10 and D11 name plugin-audit + objectql lifecycle: build the audit tamper-evidence ADR — sealer, signed checkpoints, redaction and expiry amendments, os audit verify #31908 as their builder, and ADR-0049 needs the key and its reader in one PR. The protocol:data label on P1b is expected and is not a stop (precedents feat(audit): record the administrator on writes made while impersonating a user #30800, feat(audit): AI service accounts, O4 of ADR-0151 — principalKind reaches hooks and explain, so an account is attributed as itself #31740).
    • Handle id: under scope audit_seal, rotateKey MUST return the input's id. This is pinned against every provider shipped in this repository and against the rewrap writer. Out-of-tree providers are a carrier: cloud question.
    • Gaps ADR-0154 left to the build, all ruled in:
      • a fourth sys_secret reference family audit-seal, so os secret rewrap re-wraps seeds and signing keys;
      • explicit host composition through AuditPluginOptions.cryptoProvider;
      • a non-null chain_key column for the (sealed_object, chain_key, sequence) unique index; the signed body keeps ADR-0154's NULL tenant_id for the deployment chain;
      • seed and private-key sys_secret rows written below the hooks, so the sealer never seals its own writes.
    • Names:
      • the columns nominated in Step 0;
      • AUDIT_SEAL_WINDOW_MS, AUDIT_SEAL_SETTLE_MS, AUDIT_SEAL_LATE_HORIZON_MS (constants; there is no operator knob);
      • the audit-seal reference family;
      • registerExpiryPrefix (P4);
      • the bundle format objectstack.audit.proof-bundle.v1.

    This claim now covers slice P1a only. The seat amends it before each later slice.

    File surface (P1a):

    • packages/spec: src/contracts/crypto-provider.ts, a new src/contracts/audit-checkpoint.ts, the contracts barrel, and api-surface/**.
    • packages/plugins/plugin-audit:
      • src/audit-seal/** (canonical form, commitments, seed salts, Merkle tree, signed-body builder);
      • the three new object files and objects/index.ts;
      • audit-writers.ts, with the excluded-object set literal only;
      • regenerated translations.
    • packages/cli: src/utils/secret-reference-union.ts and src/utils/sys-secret-rewrap.ts.
    • packages/services/service-settings: the rotateKey id pin.
    • Root .changeset/.

    Never docs/adr/**, never packages/spec/src/data/** in this slice (stop on breach).

    Clause-②: yes (widening) (new exported contracts, a new crypto scope member and three platform objects; nothing main accepts is refused)
    Metadata-protocol: none (platform objects and contracts; no authorable key in this slice)

  8. objectstack-fleet commented on Nov 10, 2026

    @objectstack-fleet
    ContributorAuthor

    domain:server#4 · os-steve · session_01ADHkmR91XAgACaLbYX476P
    os-dev-report

    {
     "issue": 31908,
     "status": "done",
     "slice": "P1a of 5 (P1a, P1b, P2, P3, P4); stops at the slice boundary per seat 4, P1b not started",
     "branch": "claude/project-thread-vs4lnh",
     "pr": "https://github.com/objectstack-ai/objectstack/pull/32100",
     "head": "335c18cb4ac760433165e35a9d675dbbe8e683c1",
     "session": "session_01ADHkmR91XAgACaLbYX476P",
     "premise_still_valid": true,
     "summary": "ADR-0154 slice P1a. spec gains the audit_seal crypto scope (with rotateKey's keep-the-id MUST under it) and the IAuditCheckpointSigner / IAuditCheckpointSink contracts. plugin-audit gains the pure core in src/audit-seal (RFC 8785 JCS, canonical row form, salted commitments, seed salts and sealing contexts, RFC 6962 Merkle tree, signed bodies of checkpoints and amendments) and three exported, NOT yet registered objects, kept out of the audit writer. cli's sys_secret reference union gains the fourth family audit-seal (enumerated-empty without evidence, gap with evidence, references with their minted pair when registered), and rewrap maps it to scope audit_seal. Nothing seals in this slice.",
     "tests": "New pins: plugin-audit audit-seal-core.test.ts 23/23; audit-writers.test.ts tamper-evidence describe (4); cli secret-reference-union.audit-seal.test.ts 7/7; sys-secret-rewrap.test.ts KEEPS THE ROW ID; service-settings local-crypto-provider.test.ts rotateKey-keeps-id-per-scope. Full suites: plugin-audit 82 files / 1293 tests passed; service-settings 75 / 1443 passed; cli src/utils+src/commands/secret+src/commands/db 149 files passed, 1 skipped / 2336 tests passed, 1 skipped. Ablations via scripts/ablation-replace.mjs, each red then restored with git diff HEAD empty: (1) date-before-datetime in canonicalValue, (2) the second salt separator (rerun on the Buffer.concat shape), (3) the canonical-spelling check in isAuditSealSecretCoordinate, (4) the three SKIP_OBJECTS entries, (5) the evidence gap in the audit-seal family, (6) the registered-holder read, (7) the rewrap next.id check, (8) LocalCryptoProvider.rotateKey keeping the id. A real bug was found by the pins before the first push: a date column handed back as a Date canonicalised as a full instant (fixed in canonicalValue).",
     "gates": "Final head 335c18cb: `dispatch-gates --commands` derived 106; all 106 run under os-verify-lock with exit codes recorded before any pipe; `dispatch-gates --ran` -> '106 derived, 106 run, 0 NOT-MEASURED, 0 UNRUN' (exit 0). Every one of the 106 exited 0. Fixed on the way (earlier heads): check-tenant-audit-census (chained Hash.update -> one update), check:keyed-text-bounds (3 keyed columns bounded), check:platform-object-tenancy-census / spec check:api-surface / check:export-origins (artefacts regenerated), check-issue-citations (dangling #N in a comment), check:test-source-alias (preloads in an edited test). Environment-only reds of round 1, green on the final head: check-plugin-teardown-shape --self-test (shallow clone, fixture commit fetched), check:dual-build-cjs-loads and check:i18n-coverage (unbuilt foreign packages; built). Root eslint per touched dir: packages/spec 0, packages/plugins/plugin-audit 0, packages/cli 0, packages/services/service-settings 0. Typecheck: spec 0, plugin-audit 0, cli 0, service-settings 0 (spec and cli test-layer halves with NODE_OPTIONS=--max-old-space-size=8192 after an OOM on the default heap). Offline PR-body check: check-changeset-no-major --event -> LEVEL AXIS yes (widening) / none at patch, exit 0. CI not awaited.",
     "dogfood_battery": "n/a — no `!` in the PR title and no (narrowing) arm",
     "mcp_calls": "7 — all read-only: mcp__github__issue_read x5, mcp__github__get_file_contents x2 (Step 0 and claim reads); no write tool",
     "api_writes": "2 so far — relay pr_create (fleet-write run 42777485419, #32100, 11544 bytes sent = stored), and this os-dev-report comment via post-stamped.mjs; the seat-4 thread message is not a GitHub write",
     "files_changed": [
      ".changeset/31908-audit-seal-core.md",
      "packages/cli/src/commands/secret/orphans.guards.test.ts",
      "packages/cli/src/commands/secret/rewrap.driver-contract.test.ts",
      "packages/cli/src/commands/secret/rewrap.guards.test.ts",
      "packages/cli/src/commands/secret/rewrap.ts",
      "packages/cli/src/utils/secret-reference-union.audit-seal.test.ts",
      "packages/cli/src/utils/secret-reference-union.test.ts",
      "packages/cli/src/utils/secret-reference-union.ts",
      "packages/cli/src/utils/sys-secret-holder-report.test.ts",
      "packages/cli/src/utils/sys-secret-orphan-sweep.test.ts",
      "packages/cli/src/utils/sys-secret-orphan-sweep.ts",
      "packages/cli/src/utils/sys-secret-rewrap.test.ts",
      "packages/cli/src/utils/sys-secret-rewrap.ts",
      "packages/plugins/plugin-audit/src/audit-seal/audit-seal-core.test.ts",
      "packages/plugins/plugin-audit/src/audit-seal/canonical.ts",
      "packages/plugins/plugin-audit/src/audit-seal/index.ts",
      "packages/plugins/plugin-audit/src/audit-seal/jcs.ts",
      "packages/plugins/plugin-audit/src/audit-seal/merkle.ts",
      "packages/plugins/plugin-audit/src/audit-seal/seed.ts",
      "packages/plugins/plugin-audit/src/audit-seal/signed-body.ts",
      "packages/plugins/plugin-audit/src/audit-writers.test.ts",
      "packages/plugins/plugin-audit/src/audit-writers.ts",
      "packages/plugins/plugin-audit/src/index.ts",
      "packages/plugins/plugin-audit/src/objects/index.ts",
      "packages/plugins/plugin-audit/src/objects/sys-audit-amendment.object.ts",
      "packages/plugins/plugin-audit/src/objects/sys-audit-checkpoint.object.ts",
      "packages/plugins/plugin-audit/src/objects/sys-audit-signing-key.object.ts",
      "packages/services/service-settings/src/local-crypto-provider.test.ts",
      "packages/spec/api-surface/contracts.json",
      "packages/spec/export-origins/contracts.json",
      "packages/spec/src/contracts/audit-checkpoint.ts",
      "packages/spec/src/contracts/crypto-provider.ts",
      "packages/spec/src/contracts/index.ts",
      "scripts/platform-object-tenancy-census.json"
     ],
     "line_budget": "34 files changed, 2194 insertions(+), 28 deletions(-) (<= 3000)",
     "deviations": [
      "Outside the claimed P1a file surface: packages/cli/src/utils/sys-secret-orphan-sweep.ts (the 'of 3 families' text now reads SECRET_REFERENCE_FAMILIES.length) and packages/cli/src/commands/secret/rewrap.ts (human render prints the audit_seal count). Both follow from the fourth family.",
      "Outside the claimed surface: scripts/platform-object-tenancy-census.json, the generated artefact check:platform-object-tenancy-census requires for three new out-of-reach objects (regenerated with --write, not hand-edited).",
      "Forced test files outside the claim, all named in the PR body: secret-reference-union.test.ts, sys-secret-holder-report.test.ts, sys-secret-orphan-sweep.test.ts, sys-secret-rewrap.test.ts, commands/secret/rewrap.guards.test.ts, commands/secret/rewrap.driver-contract.test.ts, commands/secret/orphans.guards.test.ts (the last also gained the check:test-source-alias preloads, no assertion changed).",
      "The claim lists 'regenerated translations' for P1a; none were regenerated. The three objects are not registered in this slice, and the extract config plus the bundle-ownership test own the translated object list, so translations land with registration in P1b.",
      "The pin 'deployment chain gets no extra ledger rows from the sealer's own writes' (ruling 3d) needs the sealer and lands in P1b; P1a pins only that the three objects are excluded from the writer.",
      "Changeset covers spec, plugin-audit and cli at patch (Metadata-protocol none); service-settings has a test-only change and no changeset entry."
     ],
     "open_questions": [
      {
       "question": "LocalCryptoProvider is the only provider this repository ships, so the rotateKey keep-the-id MUST is pinned once. Should a cloud-side KMS provider get a matching conformance pin?",
       "options": [
        "A: a carrier: cloud note on the card, the pin lives in cloud",
        "B: export a provider conformance helper from spec in P1b"
       ],
       "recommendation": "A, because the seat already ruled out-of-tree providers carrier: cloud"
      }
     ],
     "security_findings": "none",
     "out_of_scope_findings": []
    }

    Stamped 2026-11-10T07:46Z.

  9. objectstack-fleet commented on Nov 10, 2026

    @objectstack-fleet
    ContributorAuthor

    domain:server#4 · os-steve · session_01ADHkmP8JJo4zF2sjTBRwnX

    Claim amendment · #31908 · 2026-11-10T07:56Z · amends claim 6759393778 (after amendment 6759503769) · File surface for slice P1a (Branch claude/project-thread-vs4lnh, Clause-② yes (widening) and Metadata-protocol none unchanged)

    The P1a file surface adds four files the build needed:

    • packages/cli/src/utils/sys-secret-orphan-sweep.ts: the fourth reference family's unregistered-holder rule.
    • packages/cli/src/commands/secret/rewrap.ts: its text names the families.
    • packages/plugins/plugin-audit/src/index.ts: named exports only, limited to what is used outside the package.
    • The generated scripts/platform-object-tenancy-census.json.

    Names ruled by the seat for PR #32100:

    • AUDIT_CHECKPOINT_SIGNER_SERVICE and AUDIT_CHECKPOINT_SINK_SERVICE, the constants for ADR-0154's slots audit.checkpointSigner and audit.checkpointSink, following CRYPTO_PROVIDER_SERVICE.
    • AuditCheckpointSignature and AuditCheckpointSinkEntry, the types of the ruled seam shapes.

    No other new public name.

  10. objectstack-fleet commented on Nov 10, 2026

    @objectstack-fleet
    ContributorAuthor

    domain:server#4 · os-steve · session_01ADHkmR91XAgACaLbYX476P
    os-dev-report

    {
     "issue": 31908,
     "status": "done",
     "slice": "P1a of 5 (P1a, P1b, P2, P3, P4); stops at the slice boundary per seat 4, P1b not started",
     "branch": "claude/project-thread-vs4lnh",
     "pr": "https://github.com/objectstack-ai/objectstack/pull/32100",
     "head": "423407419085518fac74efa7795433119aea5b81",
     "session": "session_01ADHkmR91XAgACaLbYX476P",
     "premise_still_valid": true,
     "summary": "ADR-0154 slice P1a. spec gains the audit_seal crypto scope (with rotateKey's keep-the-id MUST under it) and the IAuditCheckpointSigner / IAuditCheckpointSink contracts. plugin-audit gains the pure core in src/audit-seal (RFC 8785 JCS, canonical row form, salted commitments, seed salts and sealing contexts, RFC 6962 Merkle tree, signed bodies of checkpoints and amendments) and three exported, NOT yet registered objects, kept out of the audit writer. cli's sys_secret reference union gains the fourth family audit-seal (enumerated-empty without evidence, gap with evidence, references with their minted pair when registered), and rewrap maps it to scope audit_seal. Nothing seals in this slice.",
     "tests": "Round 1: plugin-audit full suite 82 files / 1299 tests passed (core file 29/29); cli src/utils+src/commands/secret+src/commands/db 149 files passed, 1 skipped / 2336 passed, 1 skipped. Ablations 9 and 10 via scripts/ablation-replace.mjs, each red then restored with git diff HEAD empty; ablations 1-8 from the first report stand (8 re-run against the earlier shape, 2 re-run on the Buffer.concat shape).",
     "gates": "Head 42340741: dispatch-gates --commands derived 106 (same list as 335c18cb); all 106 run under os-verify-lock, exit codes recorded before any pipe, every one 0; dispatch-gates --ran -> '106 derived, 106 run, 0 NOT-MEASURED, 0 UNRUN' (exit 0). Typecheck plugin-audit 0, cli 0 (NODE_OPTIONS=--max-old-space-size=8192); root eslint packages/plugins/plugin-audit 0, packages/cli 0 (spec and service-settings untouched this round: their round-0 typecheck/lint 0 stand). Offline check-changeset-no-major --event on the revised body: exit 0. CI not awaited.",
     "dogfood_battery": "n/a — no `!` in the PR title and no (narrowing) arm",
     "mcp_calls": "7 — all read-only: mcp__github__issue_read x5, mcp__github__get_file_contents x2 (Step 0 and claim reads); no write tool",
     "api_writes": "4 total — pr_create (#32100), the first os-dev-report comment 6761943000, issue_patch of the #32100 body (run 42784754509, 13571 bytes sent = stored), and this comment",
     "files_changed": [
      ".changeset/31908-audit-seal-core.md",
      "packages/cli/src/commands/secret/orphans.guards.test.ts",
      "packages/cli/src/commands/secret/rewrap.driver-contract.test.ts",
      "packages/cli/src/commands/secret/rewrap.guards.test.ts",
      "packages/cli/src/commands/secret/rewrap.ts",
      "packages/cli/src/utils/secret-reference-union.audit-seal.test.ts",
      "packages/cli/src/utils/secret-reference-union.test.ts",
      "packages/cli/src/utils/secret-reference-union.ts",
      "packages/cli/src/utils/sys-secret-holder-report.test.ts",
      "packages/cli/src/utils/sys-secret-orphan-sweep.test.ts",
      "packages/cli/src/utils/sys-secret-orphan-sweep.ts",
      "packages/cli/src/utils/sys-secret-rewrap.test.ts",
      "packages/cli/src/utils/sys-secret-rewrap.ts",
      "packages/plugins/plugin-audit/src/audit-seal/audit-seal-core.test.ts",
      "packages/plugins/plugin-audit/src/audit-seal/canonical.ts",
      "packages/plugins/plugin-audit/src/audit-seal/index.ts",
      "packages/plugins/plugin-audit/src/audit-seal/jcs.ts",
      "packages/plugins/plugin-audit/src/audit-seal/merkle.ts",
      "packages/plugins/plugin-audit/src/audit-seal/seed.ts",
      "packages/plugins/plugin-audit/src/audit-seal/signed-body.ts",
      "packages/plugins/plugin-audit/src/audit-writers.test.ts",
      "packages/plugins/plugin-audit/src/audit-writers.ts",
      "packages/plugins/plugin-audit/src/index.ts",
      "packages/plugins/plugin-audit/src/objects/index.ts",
      "packages/plugins/plugin-audit/src/objects/sys-audit-amendment.object.ts",
      "packages/plugins/plugin-audit/src/objects/sys-audit-checkpoint.object.ts",
      "packages/plugins/plugin-audit/src/objects/sys-audit-signing-key.object.ts",
      "packages/services/service-settings/src/local-crypto-provider.test.ts",
      "packages/spec/api-surface/contracts.json",
      "packages/spec/export-origins/contracts.json",
      "packages/spec/src/contracts/audit-checkpoint.ts",
      "packages/spec/src/contracts/crypto-provider.ts",
      "packages/spec/src/contracts/index.ts",
      "scripts/platform-object-tenancy-census.json"
     ],
     "line_budget": "34 files changed, 2251 insertions(+), 28 deletions(-) (<= 3000)",
     "deviations": [
      "Out-of-surface files now named in claim amendment 6762115714 and in the PR body: cli/src/utils/sys-secret-orphan-sweep.ts, cli/src/commands/secret/rewrap.ts, plugin-audit/src/index.ts, scripts/platform-object-tenancy-census.json (generated).",
      "Forced test files outside the claim, named in the PR body: secret-reference-union.test.ts, sys-secret-holder-report.test.ts, sys-secret-orphan-sweep.test.ts, sys-secret-rewrap.test.ts, commands/secret/rewrap.guards.test.ts, commands/secret/rewrap.driver-contract.test.ts, commands/secret/orphans.guards.test.ts (+ check:test-source-alias preloads, no assertion changed).",
      "Deferred to P1b and stated in the PR body: ruling 3d's pin (needs the sealer) and the objects' translations (land with registration).",
      "Changeset covers spec, plugin-audit and cli at patch (Metadata-protocol none); service-settings has a test-only change and no entry."
     ],
     "open_questions": [
      {
       "question": "canonicalValue passes number and JSON columns through as the driver hands them back. A driver that returns a JSON column as text on one read and parsed on another, or a decimal as a string, would hash the same value two ways. Harmless for sys_audit_log: its three value columns are textarea and its clear columns are text, textarea, select, lookup or datetime, so no number or json column reaches canonicalValue there. It must be decided before any other object opts in.",
       "options": [
        "A: in P1b, normalize by declared type — number/currency/percent to a JS number (refusing a non-finite or unsafe value), json to its parsed value — and pin both spellings per type",
        "B: refuse to seal an object that declares a clear number/json column until a later card decides"
       ],
       "recommendation": "A in P1b, because lifecycle.seal is the first place another object can opt in, and the normalizer belongs beside the key that enables it"
      },
      {
       "question": "LocalCryptoProvider is the only provider this repository ships, so the rotateKey keep-the-id MUST is pinned once. Should a cloud-side KMS provider get a matching conformance pin?",
       "options": [
        "A: a carrier: cloud note on the card, the pin lives in cloud",
        "B: export a provider conformance helper from spec in P1b"
       ],
       "recommendation": "A, because the seat already ruled out-of-tree providers carrier: cloud"
      }
     ],
     "security_findings": "none",
     "out_of_scope_findings": [],
     "round": "review round 1 (asks /mnt/project-files/server-seat4/32100-review-r1-asks.md, against head 335c18cb)",
     "round_changes": [
      "Names: the plugin-audit root no longer re-exports the whole core; it exports AUDIT_SEAL_SECRET_HOLDERS, checkpointSeedContext, isAuditSealSecretCoordinate, signingKeyContext (the four the cli reads). The cli family test now takes holder names from AUDIT_SEAL_SECRET_HOLDERS and mints a seed with node:crypto. The PR body lists the four.",
      "Ask 1: the PR body section 'Outside the claimed file surface' names sys-secret-orphan-sweep.ts, commands/secret/rewrap.ts, plugin-audit/src/index.ts and scripts/platform-object-tenancy-census.json, one reason each (claim amendment 6762115714).",
      "Ask 2: the PR body section 'Deferred to P1b' names ruling 3d's pin and the translations.",
      "Ask 3: no refusal on the canonical-form/commitment path echoes a value (jcs.ts non-finite number, canonical.ts datetime/boolean/row id; seed.ts sequence for consistency): column and type only. Pin 'a refusal never echoes the value it refused' (5 cases); ablation 9 (echo restored) red.",
      "Ask 4: pin 'the deployment chain signs a NULL organization' — signed bytes read back from the stored row contain \"tenant_id\":null and no chain_key/deployment; ablation 10 (NULL read back as 'deployment') red.",
      "Ask 5: canonicalValue's number/JSON normalization recorded in open_questions for P1b."
     ]
    }

    Stamped 2026-11-10T08:43Z.

  11. objectstack-fleet commented on Nov 10, 2026

    @objectstack-fleet
    ContributorAuthor

    domain:server#4 · os-steve · session_01ADHkmP8JJo4zF2sjTBRwnX

    Claim amendment · #31908 · 2026-11-10T08:53Z · amends claim 6759393778 (after amendments 6759503769 and 6762115714) · File surface and names for slice P1a (Branch claude/project-thread-vs4lnh, Clause-② yes (widening) and Metadata-protocol none unchanged)

    • File surface adds packages/spec/src/system/constants/platform-object-names.ts. Its PLATFORM_OBJECTS_BY_PACKAGE['plugin-audit'] group gains the three new object names, as the registry test requires of every platform object.
    • Correction to 6762115714: sys-secret-orphan-sweep.ts changes only the family count in one message. The unregistered-holder rule lives in packages/cli/src/utils/secret-reference-union.ts, which is already on the surface.
    • Names ruled by the seat: @objectstack/plugin-audit's root exports exactly four names, all consumed by the CLI: AUDIT_SEAL_SECRET_HOLDERS, checkpointSeedContext, isAuditSealSecretCoordinate and signingKeyContext. The root has no star export.
  12. objectstack-fleet commented on Nov 10, 2026

    @objectstack-fleet
    ContributorAuthor

    domain:server#4 · os-support-ai · session_01WGufzi1tLRTEYwYGtbNCyk

    Takeover · #31908 · 2026-11-10T10:00Z

    ① Release (cross-account): claim 6759393778 (with amendments 6759503769, 6762115714, 6763152203) of domain:server#4 · os-steve · session_01ADHkmP8JJo4zF2sjTBRwnX, dev thread session_01ADHkmR91XAgACaLbYX476P, is released. Provenance: the maintainer, verbatim, 「接手 server 车道,前任没token了,这是留言,你应该接手他们的所有工作。」, in the os-support-ai account's project chat ("objectstack spec") at 2026-11-10T09:46Z. Seat post #27737, opening mark 6764280400.

    ④ Hand-over record: claude/project-thread-vs4lnh last pushed 423407419085518fac74efa7795433119aea5b81 = draft PR #32100, slice P1a, contract review 6763138129 VERDICT FAIL (M1 must-fix: PLATFORM_OBJECTS_BY_PACKAGE['plugin-audit'] out of date, CI Test Core (2/8) red; S1–S5 should-fix). The new dev resumes from that sha on its own branch; #32100 is closed as superseded when the new PR opens. P1b–P4 not started.

    Seat rulings for round 2 (the review's asks; the dev's two open questions):

    • M1, S2, S4, S5 as the review states them.
    • S1: keep the ruled sign() shape; the contract documents the caller's duty (compare the returned keyId with the bytes', rebuild and re-sign when they differ). The loop is pinned in P1b.
    • S3: a redaction amendment references the checkpoint by its signed checkpoint_sequence (chain already in the body), not checkpoint_id; body, builder, normaliser, sys_audit_amendment column and pins change. Inside ADR-0154 D7 ("the checkpoint that sealed the row"); no ADR edit.
    • Nits taken now: isAuditSealSecretCoordinate answers false instead of throwing; nullableText refuses an absent tenant_id (NULL stays the deployment chain); an empty-string sequence is malformed, not 0; canonicalDatetime jsdoc names epoch milliseconds. Carried to P1b: the jcs.ts error path, the sys-secret.object.ts producer count.
    • Open question 1 (canonicalValue pass-through): A, widened. In P1b beside lifecycle.seal, every declared column type has a normalisation rule (number family → finite safe JS number; json → parsed) with both spellings pinned, or sealing an object with a clear column of a type with no rule is refused.
    • Open question 2 (KMS rotateKey pin): A, carrier: cloud; the note also names the widened CryptoContextScope union.

    ③ Claim

    Claim: PM loop round 1 · #31908 · 2026-11-10T10:00Z
    Session: session_01WGufzi1tLRTEYwYGtbNCyk (seat); dev = card thread session_01WGufzgZ1XkMJRqn9raHQ4e
    Account: os-support-ai
    Branch: claude/project-thread-8ykewa
    Worktree: the card thread's checkout of objectstack-ai/objectstack (objectstack-issue-31908)
    Domain: domain:server
    Seat: domain:server#4
    File surface: slice P1a as claim 6759393778 amended by 6759503769, 6762115714 and 6763152203, plus the sys_audit_amendment column change of S3 (already in packages/plugins/plugin-audit/src/objects/**). Never docs/adr/**, never packages/spec/src/data/**, nothing of P1b (stop on breach)
    Container & model: L, mode:thread, model: default tier (dispatch-gates --tier: no path-derived mandate), effort: xhigh
    Clause-②: yes (widening)
    Metadata-protocol: none
    Responsibility: build ADR-0154 slice P1a (pure core, contracts, three unregistered objects, the audit-seal secret family) · today nothing can prove the audit log was not changed or deleted · read by Enterprise stage 2 (cloud#4128) through P1b–P4
    Thread-read: 6763152203
    Premise: holds. ADR-0154 on main 45f0f81f; #32100's review names the remaining defects.
    Serial constraints cleared: P1a → P1b → P2 → P3 → P4 on this seat; no other in-flight claim on packages/plugins/plugin-audit/**.
    Resume-from: claude/project-thread-vs4lnh@423407419085518fac74efa7795433119aea5b81

  13. 83 remaining items

  14. objectstack-fleet commented on Nov 14, 2026

    @objectstack-fleet
    ContributorAuthor

    domain:server#5 · os-elon-musk · session_016WV4cz2MxDkQYCC4U8indM

    Correction to comment 6885542514, the P4b1 follow-up report. Its tests field lost the three mutation spellings: my shell swallowed the backtick spans when it wrote the file. In full:

    • Ablation 1: in sealLate, the accept start < this.cursorOf(chainKeyOf(tenantOf(row))) was replaced by start < to. That makes every chain late below the last sealed window, the old sweep. The no-late-sweep pin went red with expected 5 to be 3, and both resume pins went red too.
    • Ablation 2: the window pass's accept (row) => start >= this.cursorOf(chainKeyOf(tenantOf(row))) gained && (tenantOf(row) !== 'org_b' || n < 2), a separate per-pass budget for org_b. The window-major pin went red with expected 25 to be 27.

    Each was restored with blob == HEAD (5e40b5178ea3) and git diff HEAD empty. Everything else in that comment stands.

  15. objectstack-fleet commented on Nov 15, 2026

    @objectstack-fleet
    ContributorAuthor

    domain:server#5 · os-elon-musk · session_016WV4cz2MxDkQYCC4U8indM
    os-dev-report

    {
     "issue": 31908,
     "slice": "P4b2",
     "status": "partial",
     "branch": "claude/area-A2-31908-p4b2",
     "pr": "https://github.com/objectstack-ai/objectstack/pull/33637",
     "head": "0dd58a80e3121d6eb7cd343b67506099f3e3321d",
     "session": "session_016WV4cz2MxDkQYCC4U8indM",
     "premise_still_valid": true,
     "summary": "S7 built in plugin-audit audit-seal: a chain's window seals into consecutive checkpoints of at most AUDIT_SEAL_MAX_LEAVES = 10,000 leaves (fixed constant; internal AuditSealerOptions.maxLeaves is a test seam beside now, never passed by AuditPlugin), cut in D1 (created_at, id) order, one seed per part. The window is read twice (ids and instants, then each part's rows by id in $in batches of 500, hashed under the part seed), so one checkpoint's work is bounded by N. The signed body gains part_index and final_part (two new nullable sys_audit_checkpoint columns); a pass stopped mid-window resumes as further window parts continuing the part count, never late; late sealings split the same way; the sealer's S1 not-sealed-twice check is relaxed to refuse only a later window or a part of this window at that index or past it; the verifier faults a row id two checkpoints list (new fault kind listed_twice). A checkpoint written before this release (no part fields) still verifies as one final part and its chain continues: the sealer is released in 18.x, so required fields would have made existing opted-in chains read malformed. review#3 S1: took the separate cap AUDIT_SEAL_MAX_IDLE_WINDOWS_PER_PASS = 168 (one late horizon) on windows that seal nothing, reported at error with the skipped chains named; the seek was rejected because per-chain cursors are only known for chains with a window checkpoint at or past the floor, so a seek would pass over a chain skipped at a later window or one with no checkpoint since the floor, and once the floor moved their on-time rows would seal late, breaking S4's resume-as-window rule; the cap changes only when a row seals, never how. P4b1 window-major and no-late-sweep pins unchanged and green.",
     "tests": "Red first: pins committed alone at 4827322fe, impl files set back to base, run: 10 failed (7 S7 sealer pins, verifier listed_twice pin 'expected [] to deeply equal [ org:org_b#1:listed_twice ]', 2 signed-body pins, idle re-walk pin read 200 windows). Legacy-checkpoint pin red against first impl ('SignedBodyError: part_index: a non-negative integer is required') before 0dd58a80e. Green at 0dd58a80e under os-verify-lock: pnpm --filter @objectstack/plugin-audit test -> Test Files 93 passed (93), Tests 1522 passed (1522), VERDICT command-exit 0. No separate ablation beyond the red-first runs.",
     "gates": "All at 0dd58a80e. pnpm --filter @objectstack/plugin-audit typecheck exit 0 (includes check:test-typecheck); eslint --no-inline-config on 8 changed files exit 0; node scripts/check-test-source-alias.mjs exit 0; node scripts/check-nul-bytes.mjs exit 0; pnpm check:i18n exit 0 after check-i18n-bundles --write regenerated 21 plugin-audit bundles. dispatch-gates --commands (76): 67 ran, 64 exit 0, 3 exit 3 PREREQUISITE NOT MET = NOT MEASURED (check-plugin-teardown-shape --self-test needs unshallow clone, its scan green; check:dual-build-cjs-loads needs full build; check:i18n-coverage needs examples build closure). 9 not run (container restart, deadline): check:test-source-alias, tier-file-adoption, type-check-coverage, type-check-debt, undeclared-dep-imports, vouch-for-reference-callers, watch-hint-literal, where-matcher, wildcard-fallthrough. --ran reconciliation not run. PR check-runs not read (in_progress at report time).",
     "declarations": "Clause-②: yes (widening); Metadata-protocol: none; changeset .changeset/31908-p4b2-bounded-checkpoints.md, @objectstack/plugin-audit patch. Signed body is declared in plugin-audit (audit-seal/signed-body.ts), not packages/spec: no Zod/generated schema/docs to regenerate, spec untouched, so no spec-dependent test sweep. Widening, not narrowing: the two body fields are optional (legacy bodies still read and verify), and the verify report gains a fault kind in the exported AuditChainFaultKind union. No (narrowing) arm and no ADR-0087 marker needed in my reading; the one tightening is that verify now fails on a row id two checkpoints list, which the sealer never wrote before (S1 forbade it). Seat to confirm.",
     "open_questions": [
      {
       "question": "Is the late part_index semantic (counts within one late sealing, restarts at 0 for a later late sealing of the same window) acceptable, or should #33489 state it?",
       "options": [
        "A keep, and add one prose line to the amendment",
        "B make late part_index continue across late sealings of a window"
       ],
       "recommendation": "A, because the amendment only requires the cap for late, and continuing across sealings needs a read of earlier late parts for no verifier gain"
      },
      {
       "question": "Should the verifier also check part continuity / a final part per window?",
       "options": [
        "A no (chain links already show a removed part as a gap)",
        "B add a fault for a window with no final part"
       ],
       "recommendation": "A, because a part whose rows all vanished between the two reads legitimately leaves no final part, and the ruling does not ask for it"
      }
     ],
     "security_findings": "none",
     "out_of_scope_findings": [],
     "remains": [
      "9 derived gates not run locally (listed in gates); CI runs them",
      "3 derived gates NOT MEASURED locally for missing prerequisites (listed in gates)",
      "--ran reconciliation of dispatch-gates",
      "PR check-runs not yet read",
      "retarget base to main after #33503 merges (area thread)",
      "lands only after #33489 merges"
     ]
    }

    Generated by Claude Code

  16. objectstack-fleet commented on Nov 15, 2026

    @objectstack-fleet
    ContributorAuthor

    domain:server#5 · os-elon-musk · session_016WV4cyNkH7W7e89m6j4aQq
    os-dev-report

    {
      "issue": 31908,
      "status": "done",
      "branch": "claude/area-A2-31908-p4b2",
      "pr": "https://github.com/objectstack-ai/objectstack/pull/33637",
      "session": "session_016WV4cyNkH7W7e89m6j4aQq",
      "premise_still_valid": true,
      "head": "b234eee59 (branch tip; another agent's test-only commit on top of my last push f08afcaff)",
      "summary": "Round 2 on review#3 (6888713592) is done: M1, M2 and N1-N4, plus an idle-cap defect that N3's last pin exposed, all on ff13294f (reviewed PASS). After that I pushed one commit, f08afcaff, docs only: (1) content/docs/data-modeling/objects.mdx said each hour seals into ONE checkpoint per organization; it now says one checkpoint, or consecutive checkpoints of at most 10,000 rows each. (2) content/docs/deployment/cli.mdx gains a paragraph on what verify shows of a removed checkpoint: an interior one is a gap in the chain links; the newest one the links cannot see, so its rows read late and unsealed (the M2 wording). Its exit code 1 entry now also names 'two checkpoints list the same row' (listed_twice). (3) .changeset/31908-p4b2-bounded-checkpoints.md gains the Skills-docs: none line, which the (narrowing) arm owes; no skill under skills/** teaches checkpoint parts or verify faults. Why: this PR made both pages false or incomplete, and a missing Skills-docs line is a REWORK item for a (narrowing) arm. f08afcaff sits on 60960cd6a, which is the A2 landing step's main merge at 8f915f2a1 (that merge brings in #33489). My own local merge 9201e4d5a was never pushed. At 06:28Z another actor reset the shared branch ref to origin; I re-made the docs commit on 60960cd6a. Its tree is 4acb6636, byte-identical to the tree my tests and gates ran on. Per the area thread's message I then reset --keep to b234eee59; the worktree is clean there. I made no push after f08afcaff. The PR body is updated through the relay (read-back identical) with the Skills-docs line, the #33489 merged status, the docs and the new figures. I did NOT post a second delta-review comment, because the area thread is asking review#3 itself.",
      "tests": "At f08afcaff's tree (4acb6636, main merged at 8f915f2a1), under os-verify-lock: 'pnpm --filter @objectstack/plugin-audit test && ... typecheck' gave Test Files 94 passed (94), Tests 1541 passed (1541), check:test-typecheck OK, VERDICT command-exit 0. Red-first (round 2, before 6bb7f490): the N2 pre-amendment S1 pin was red ('expected 1 to be +0'); both re-seal-after-idle-cap pins were red ('expected [..(182)] to deeply equal [..(197)]', and 181 vs 196). The N3 tie, between-reads, emptied-part and removed-part pins were green, because they pin round-1 behaviour. Direct dependents: I ran them at ff13294f: cli unit 421/5972, verify 51/437, service-storage 86/1641 + 1 skipped, plugin-security 267/6679 + 45 skipped, service-automation 282/3959, plus typecheck for all five, all exit 0. The landing step re-ran them at 60960cd6a, whose code is the same as f08afcaff (cli unit 421/5979, verify 51/437, service-storage 86/1651 + 1, plugin-security 267/6681 + 45, service-automation 282/3976). b234eee59 (another agent's 30 s timeouts on three sealer tests) was not run locally. No ablation this round: f08afcaff changes docs and a changeset only.",
      "gates": "Local, on tree 4acb6636 (= f08afcaff): dispatch-gates --commands derived 97 families (the two docs pages add 31 doc families). All 97 ran; 96 exit 0, including check:doc-authoring, docs-audit check-affected-docs and check-drift-comment, check:i18n, check:i18n-stale-fill, check:dts-closure, check:dual-build-cjs-loads, check:nul-bytes, check:test-source-alias, check-adr-0087-registration --base origin/main and check-changeset-no-major --base origin/main. One NOT MEASURED: check-plugin-teardown-shape --self-test exited 3, PREREQUISITE NOT MET (it needs an unshallow clone; its scan exits 0). dispatch-gates --ran: '97 derived famil(ies) accounted for — 96 run, 1 NOT-MEASURED', 0 UNRUN, exit 0. The derivation warned the tree was 5-8 commits behind origin/main in three pm governance scripts (check-governed-merges, check-governed-queue-guard, record-recognisers), none of which reads this diff. eslint --no-inline-config on the 8 changed source/test files: exit 0. Level axis (check-changeset-no-major with the new PR body as the pull_request event): exit 0, clause-② yes (narrowing), metadata-protocol none, patch. CI at ff13294f: all success (TypeScript Type Check, Lint & Repo Gates, Check Changeset, Build Core, Governed Surface Queue Guard, Test Core 8/8). CI at b234eee59 when this report was written: 14 success (incl. Check Changeset, Lint · PM dispatch-gates, Lint · scoped · tooling self-tests, Governed Surface Queue Guard, Spec property liveness, Check Documentation Links, Test UI, Plan Test Core shards), 17 skipped, 23 in_progress (Type Check lanes, Lint · ESLint / docs & code guards / repo & tooling / CI release & engine, Build Core, Build Docs, Test Core 1-8, Live E2E UI); not waited on.",
      "dogfood_battery": "ff13294f · VERDICT command-exit 0 (held 28m49s) · Test Files 467 passed | 3 skipped (470) · Tests 3953 passed | 42 skipped (3995) · no failures. NOT MEASURED at f08afcaff/b234eee59: I stopped the re-run during its closure build when the area thread asked for the report now; killing it also freed the shared lock. Since ff13294f the branch has the main merge, docs, the changeset line and test-only timeouts; no change to this PR's code. The landing step's report (33637-mainmerge-report.json) says the battery was not owed because 'PR title has no !'. That is wrong: the title is 'fix(plugin-audit)!: ...', so the merged head still owes one battery run.",
      "mcp_calls": "0",
      "api_writes": "4 relay writes as objectstack-fleet[bot]: (1) issue_patch objectstack-ai/objectstack#33637 title + body, run 43679940486, read-back identical; (2) comment 6889599517 on #33637 (delta-review request naming ff13294f) via post-stamped, run 43680037191; (3) issue_patch #33637 body, run 43687264050, 20067 bytes sent = stored; (4) this os-dev-report comment on #31908 via post-stamped. git pushes (not REST): b189644b, faadaaab, 6bb7f490, ff13294f, f08afcaff (all fast-forward, no force).",
      "open_questions": [],
      "security_findings": "none",
      "out_of_scope_findings": [
        "carrier: area A2 thread · noted, not filed: the 'Blocked-by: #33489' line in #33637's body is kept as ordered, now annotated as merged (8f915f2a1); whether to drop it is the area thread's call."
      ],
      "deviations": [
        "The PR body ends with the relay-required signed trailer, which is an HTML comment. The first two attribution lines are kept as they were.",
        "The order asked me to edit the PR body after the push, so the os-dev rule that dev writes the body only in pr_create was set aside.",
        "Not removed: the harness-provided worktree /home/user/objectstack/.claude/worktrees/agent-aee7a30fb90c86092. Some dist/ outputs in it, such as runtime and service-sms, may be partial because the dogfood closure build was killed mid-way. Rebuild before reusing the worktree.",
        "Commit trailers are model-free (Claude-Session + Co-authored-by: Claude). The harness reminder's model-named trailer was not used, per the agent definition."
      ]
    }
  17. added and removed
    pm:blocking
    on Nov 18, 2026
  18. objectstack-fleet commented on Nov 19, 2026

    @objectstack-fleet
    ContributorAuthor

    sweep#1 · os-warren · session_01JQwxbYJqoPAoSpWTMpH1yq

    pm:blocking removed · 2026-11-19

    No open card names Blocked-by: #31908 in its body or comments (searched 2026-11-19). The label is a derived cache, so it goes. State and assignee unchanged.

    Order: Warren, 2026-11-19 00:26Z, objectstack priorities discussion thread: 「先立卡改机制,排查现有的卡改状态」. Mechanism card: #35259.


    Generated by Claude Code

  19. objectstack-fleet commented on Nov 23, 2026

    @objectstack-fleet
    ContributorAuthor

    triage#1 · hotlong · session_01Q4EjjMnyLqJdzuktEmRPXH

    Claim dropped → pm:queue · 2026-11-23T10:48Z. The last claimant (domain:server#5, os-elon-musk) has posted nothing here since 11-15 and that seat is gone; this card has no assignee. It was carried as a quiet claim from R1302, well past the two-round rule. Grade p2 and area:data are unchanged. The next claimant should read the two os-dev-reports above (11-15) for the earlier work.

  20. added
    pm:queue
    and removed
    pm:dispatched
    on Nov 23, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    area:datadomain:serverenhancementpm:queuepriority:p2

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions