Skip to content

feat(fleet-write): advisory_list, a sealed listing of the triage, draft and closed advisories - #31418

Merged
objectstack-fleet[bot] merged 3 commits into
mainfrom
claude/project-thread-jp9pen
Nov 8, 2026
Merged

objectstack-fleet[bot] merged 3 commits into
mainfrom
claude/project-thread-jp9pen

Conversation

@objectstack-fleet

@objectstack-fleet objectstack-fleet Bot commented Nov 8, 2026 •

Copy link
Copy Markdown
Contributor

Requested by Irene · project thread

Fixes #31368

维护者速读

需要你做的: 无。本 PR 为 Tier S(check-governed-merges.mjs --pr 实测,命中 .claude/** 一条),仍欠契约审查(contract review)记录,通过后由席位落地。

点名问题(这一集合读权限是否也需要你的点名,如同 advisory_read 当初那样?)已答复。你在项目线程中(2026-11-08)说:「我希望安全席位不需要我插手可以自己读取问题处理修复」(gloss: "I want the security seat to read the issues and handle the fixes on its own, without my stepping in")。

做了什么:中继新增只读操作 advisory_list,列出本仓 triage/draft/closed 三态全部公告,每条只留五个字段,加密封给座位的一次性公钥;公开的运行里只写“成功”或“失败”。安全席章程的接收 ② 与巡查改为用这份列表比对台账。无工作流或 App 权限改动。

The row's contract

  • Op: advisory_list, required: ['public_key'], optional: [], alone: true. The caller passes no state, page, cursor or query.
  • Path: GET /repos/{owner}/{repo}/security-advisories?state=<s>&per_page=100[&after=<cursor>], for s in triage, draft, closed, walked in that order. ADVISORY_LIST_PAGE_PATH_SHAPE is the only query shape the refused family admits. The bare collection is still reached by the draft's POST alone; any other query, verb or tail stays refused (validate.mjs pins the variants).
  • Paging: the platform's own cursor. after is taken only from exactly one rel="next" link whose origin is this API's, whose path is exactly this repository's collection, whose state equals the walk's and whose after matches ADVISORY_LIST_CURSOR_SHAPE ([A-Za-z0-9+/=_-], 1–256 chars). Anything else is FAILED with nothing emitted. The cursor is never logged. Every page's Link is read; rel is matched case-insensitively (RFC 8288). A short page with no next link, or a full page with none, ends a state; a short page that still names a next page is FAILED. Hitting ADVISORY_LIST_PAGE_CAP (3 pages of 100 per state) is FAILED, never a truncated answer. A repeated id across pages is FAILED.
  • Projection, before sealing: exactly ghsa_id, state, severity, created_at, updated_at (ADVISORY_LIST_FIELDS). Plaintext is { count, advisories }. Each page is fenced first: every item is an advisory in the asked state with a well-formed id, severity is one of critical/high/medium/low or null, and both dates are ISO-8601 strings. Anything else is FAILED with nothing emitted, and the sentence echoes no value.
  • Cap (measured, binds first): the plaintext is padded with trailing spaces to exactly 29,939 bytes, so every sealed listing is 40,000 characters in 10 notice parts whatever the count. Measured with fake items, that ceiling is 206 advisories at 144 bytes each (critical severity) up to 215 at 138 bytes (no severity). It binds long before the page cap (300 per state). One more advisory than fits is FAILED with nothing emitted. The self-test pins that zero, one and the largest count that fits seal to the same length and 10 parts, and that one more is refused.
  • Fence: sender gate target-write, the same as advisory_read by the maintainer's ruling, checked before the first GET (refused means not sent, zero requests). Token: stroke-scoped repository-advisories: read through the row's grant; the validator writes permission_repository_advisories=read for this stroke, the path the workflow already carries for advisory_read. No .github/** or App permission change.
  • Sealing: the same X25519 + HKDF-SHA256 + AES-256-GCM seal as advisory_read, to the action's one-time key. Associated data comes from a shared advisorySealAad: advisory_read's bytes are unchanged (pinned byte for byte against the old spelling), and advisory_list's binds request id, action index and op=advisory_list, so neither answer opens as the other. The seat opens it and prints it to stdout on --reveal alone; the trailing-space trim applies to advisory_list's display only, and the open stays byte for byte. advisory_read's --reveal path is untouched.
  • Public surface: no id, count, state, severity or cursor in any log line, step summary, row or annotation. The row says only that the listing landed (sealed) or failed, with a fixed sentence.

Charter: before and after

.claude/skills/pm-dispatch/references/lanes/security.md

  • L17 before: - 接收 ②:无门铃的 \triage` 公告(外报或中继实测):经 `advisory_read` 读,座位贴记 `received`。`
  • L17 after: - 接收 ②:列表比出的无台账编号(外报、无门铃或席空时建):记 \received`,经 `advisory_read` 读。`
  • L20 before: - 云席列不了本仓公告,中继也拒裸集合:编号只来自维护者、门铃或中继实测。
  • L20 after: - 巡查:每轮中继 \advisory_list` 列 `triage`/`draft`/`closed` 比台账;缺行照接收 ②,状态不符即改。`

L21 (--reveal stdout only) and L22 (opaque ledger) already cover the output and opacity rules and are unchanged. security-findings.md does not restate the rule and is untouched.

Line readings

  • .claude/skills/pm-dispatch/references/lanes/security.md: 53 → 53, every line within the 120-byte budget.
  • .claude/skills/pm-dispatch/references/security-findings.md: 65 → 65 (unchanged).
  • node scripts/pm/check-skill-line-ratchet.mjs: exit 0.

Batteries

Self-test Before After Battery floor
validate.mjs 340 cases / 17 batteries 361 / 18 17 → 18
execute.mjs 284 / 24 306 / 25 24 → 25
dispatch.mjs 349 / 29 358 / 30 29 → 30

Ablations, each run then restored: projection off, pad off, the read's AAD changed, any query admitted by the refused family, the cursor host check off, the short-page next check off, the field fence off, and case-sensitive rel. Each reds at least one battery.

Other sites found (not edited)

  • .github/workflows/fleet-write.yml, the permission-repository-advisories mint comment: it names advisory_read as the one read-only consumer of this input. After this PR advisory_list shares it, so the comment is incomplete. Outside this surface; the seat will file it.
  • .claude/skills/pm-dispatch/references/rest-channel.md L50: lists advisory_create 等 and advisory_read. It is a "等" list, not an enumeration, so it is not stale. Not edited.

Notes

  • If dispatch-gates mandates a contract-review tier, that mandate is waived by the maintainer's standing order in this project (2026-11-03).
  • The new op has not been run against the live repository: the relay workflow runs from main, and acceptance is measured after merge.
  • Tests use obviously fake ids built the way the existing advisory_read batteries build theirs. No advisory content appears in this PR.
  • Changeset: skip-changeset (repo tooling only).

🤖 Generated with Claude Code

https://claude.ai/code/session_01J8VVAnrDeFPtUpYSMR9V1V

…isories

One relay row lists the repository's triage, draft and closed advisories:
the caller passes its one-time public_key and nothing else. The executor
walks each state on the platform's own cursor (per_page 100, a short page
or no rel="next" ends a walk, a 3-page cap per state FAILS), takes a next
cursor only from one link on this API's collection and state in a closed
shape, projects each advisory to ghsa_id, state, severity, created_at and
updated_at before the seal, pads the JSON to the channel's full size and
seals it exactly as advisory_read seals, so every listing is ten parts of
4,000 characters whatever the count. Nothing but landed or failed, the
status and the call reaches the public run.

The row spends repository-advisories at read, travels alone, and keeps
advisory_read's target-write sender gate, judged before the first GET.
The seat side opens it on the existing sealed-read path; advisorySealAad
is the one associated-data spelling, advisory_read's bytes unchanged.

Claude-Session: https://claude.ai/code/session_01J8VVAnrDeFPtUpYSMR9V1V
Co-authored-by: Claude <noreply@anthropic.com>
…y listing

The security lane's intake ② and standby patrol now take unledgered ids
from the relay's advisory_list read, sealed to the seat's key, instead of
saying the cloud seat cannot list the repository's advisories. Line-neutral.

Also: the listing battery's off-host and off-path next links now carry an
encoded cursor, so they reach the host and path check rather than failing
the cursor shape first; and the cap comment states the measured ceiling.

Claude-Session: https://claude.ai/code/session_01J8VVAnrDeFPtUpYSMR9V1V
Co-authored-by: Claude <noreply@anthropic.com>
@objectstack-fleet objectstack-fleet Bot added the skip-changeset PR has no user-facing published change; bypasses the changeset gate label Nov 8, 2026
@github-actions github-actions Bot added size/l documentation Improvements or additions to documentation labels Nov 8, 2026
@objectstack-fleet

Copy link
Copy Markdown
Contributor Author

domain:skills#3 · huangyiirene · session_01J8VVAj7CvjkGXvgXzd6RZ7

Contract-review-claim: session_01J8VVAj7CvjkGXvgXzd6RZ7 · head d5f61a8 · 2026-11-08T07:02Z

Full contract review of PR #31418 (#31368, claim 6718064948). The seat review runs at CONTRACT_REVIEW_TIER in an isolated subagent. This is a security-boundary change (a new sealed read row on the relay).

@objectstack-fleet

Copy link
Copy Markdown
Contributor Author

domain:skills#3 · huangyiirene · session_01J8VVAj7CvjkGXvgXzd6RZ7

Contract review

Served-tier: CONTRACT_REVIEW_TIER
Head-sha: d5f61a88bf36dae618063edc2e6f861b9228e5f8
Local-runs: probe — the fleet-write self-tests, the line ratchet and a no-network scratch probe of the pure list helpers, run from a detached worktree of the head to confirm the battery counts and the projection on fake values (details under Gates); the worktree is removed
Scope: scripts/pm/fleet-write/ops.mjs, scripts/pm/fleet-write/validate.mjs, scripts/pm/fleet-write/execute.mjs, scripts/pm/fleet-write/dispatch.mjs, .claude/skills/pm-dispatch/references/lanes/security.md

Read: card #31368 body and all 2 comments (triage 6717361763, claim 6718064948); the dispatch order order-31368.md; the PR body body-v1.md and the live body (the same text except a trailing newline); gates-d5f61a88.txt; AGENTS.md (changeset rule, §Post-Task step 3); the full net diff origin/main...refs/seat3/pr-31418 (2 commits); rest(), advisoryPlatformText, openRunAdvisoryReads, ADVISORY_READ_OPS, noteResponse at head; seat-lifecycle.md 〈停止条件与待命〉; check-runs on the head sha.

① Derived judgments

  1. required is ['public_key'] alone. Holds. ops.mjs:2577-2585: required: ['public_key'], optional: []. The states come from the frozen table ADVISORY_LIST_STATES (ops.mjs:1782). requests() carries only { publicKey } (ops.mjs:2584). The executor walks the table (execute.mjs:1213). validate.mjs refuses state, states, per_page, page, after, before, sort, direction, query, ghsa_id, private_key and body by name (battery at validate.mjs:2062, case "refused BY NAME"). execute.mjs repeats this end to end (refused with zero requests, case at about execute.mjs:3221).
  2. Grant, alone and gate. Holds. grant: 'read', senderGate: 'target-write', alone: true (ops.mjs:2579-2583). The grant ledger pins ['advisory_read','advisory_list'] (validate.mjs, "the grant ledger"). The minted output is permission_repository_advisories=read (validate.mjs, "fence grant: a listing's stroke"). In the executor, the gate is checked at execute.mjs:1209, before the walk loop at :1213. Any value other than target-write, including a prototype key, returns not sent. Test execute.mjs:3208 pins seen == [PERM], so zero listing GETs are sent. Note: the stroke's own sender-permission GET (/collaborators/{login}/permission) still runs first. That is the stroke gate, the same as advisory_read, and it is not a collection read.
  3. Cursor. Holds. advisoryListNextCursor (ops.mjs:1819-1845) follows a link only when there is exactly one rel="next", its origin equals api's origin, its pathname equals /repos/${repo}/security-advisories, it has exactly one state equal to the walk's state, and it has exactly one after matching ADVISORY_LIST_CURSOR_SHAPE (ops.mjs:1792, [A-Za-z0-9+/=_-]{1,256}). Anything else returns the fixed ADVISORY_LIST_CURSOR_REFUSED, and the executor returns FAILED at execute.mjs:1236 with nothing emitted. The next request is the relay's own spelling (advisoryListPagePath, ops.mjs:1799, encodeURIComponent). The link is never followed as given. The cursor is never logged: rest() puts it in r.call, but advisoryListAction never reads r.call. The row prints advisoryListCall (ops.mjs:1804). The unreached branch drops the exception text (execute.mjs:1219).
  4. Page cap and repeats. Holds. ADVISORY_LIST_PAGE_CAP = 3 (ops.mjs:1786) is pinned in validate.mjs ("under a cap of 3 pages a state"). A walk still pending after 3 pages returns ADVISORY_LIST_CAP_HIT (execute.mjs:1216,1240). A repeated id returns ADVISORY_LIST_REPEATED (execute.mjs:1227). The seen set spans all three states. Both cases emit nothing (tests "3-page cap" and "listed twice"). See should-fix S1 for one truncation edge.
  5. Constant-size pad. Holds. ADVISORY_LIST_PADDED_BYTES = 40000·3/4 − 61 = 29939 (ops.mjs:1869). advisoryListPadded (ops.mjs:1876) returns null when the JSON is too large. The executor returns OVER_CAP before sealing (execute.mjs:1242-1243). After sealing it re-checks: exactly 40,000 base64url characters (:1251) and exactly 10 parts (:1253). validate.mjs:2128 pins 0, 1 and max-fit items to [40000, 10, n], with one more returning null. execute.mjs:3179 pins every non-ciphertext line, row and summary as byte-identical for 0, 5 and 150 items. ADVISORY_LIST_LANDED (ops.mjs:1926) has no digits. The validate sentence sweep pins digits to the caps and statuses alone.
  6. AAD and --reveal. Holds. advisoryReadAad (ops.mjs:1595) is not in the diff. advisorySealAad with op advisory_read delegates to it (ops.mjs:1892-1896). validate.mjs:2133 pins Buffer.compare == 0 and the literal old spelling fleet-write:advisory_read:v1 request=… action=1 ghsa_id=…. My probe confirms the bytes are identical. The list AAD binds op=advisory_list where the read AAD binds ghsa_id=, so the two cannot collide. Both cross-opens are tested as refused. At the seat, the open uses r.op, which comes from the payload action, not from the annotation (dispatch.mjs:1380,1420). The --reveal line dispatch.mjs:4072 changes only the advisory_list branch. advisory_read still prints r.plaintext unchanged. The trim runs at display time only. The open and the --json byte count use the padded plaintext (dispatch.mjs battery at :3133, "BYTE FOR BYTE the padded listing").
  7. No id, count, state or severity on a public surface. Holds. Every failure sentence is fixed or names a status alone (ops.mjs:1849-1855,1899-1928). The platform message passes only through the advisoryPlatformText whitelist (ops.mjs:1286, used at execute.mjs:1224). GETs are unpaced, so no pace-log line is written per page (execute.mjs:1376, isWriteMethod). The marker sweep across 32 runs finds no marker, listed id or cursor in logs, rows, summary, annotation messages or pace lines (execute.mjs:3230). Fake ids only: the diff's only id-shaped literals are the GHSA-<k>-2345-wxyz family and the swapped form of the existing fake constant, which already appears on main. The PR body has none.
  8. No .github/** or App permission change. Holds. The diff touches 5 files, none under .github/**. The workflow's existing permission-repository-advisories input from validator output is unchanged (pinned in validate.mjs, "mints … from the validator's output"). The advisory_create POST fence still holds: the request ledger pins advisory_create POST …/security-advisories and advisory_list GET …/security-advisories as the only collection requests (validate.mjs:1880). The refused family at ops.mjs:2640 admits the bare collection or exactly the listing query (ADVISORY_LIST_QUERY_SOURCE). refusedTails (validate.mjs:1868) pins 19 query variants as refused. The "out of reach of every row" sentence was rewritten at ops.mjs:460-470, the ADVISORY_CREATE_PATH_SHAPE doc at ops.mjs:1100-1103, the REFUSED_PATH_FAMILIES comment, and the PERMISSIONS, STROKE_SCOPED and row-legend comments ("six" became "seven"). A grep at head for listing advisories|never a GET|no row spells|the one GET|six advisory|拒裸集合|中继实测 finds only the rewritten sentence. One stale fragment remains at validate.mjs:138 (nit N1).
  9. Charter edit. Holds. security.md is 53 lines, ceiling 53. L17 is 120 bytes and L20 is 119 bytes, both within budget. L17 now takes ids from the listing diff. L20 runs advisory_list each patrol round over triage/draft/closed and compares it with the ledger: a missing row follows 接收 ②, a state mismatch is corrected. L21 (--reveal stdout only) and L22 (opaque ledger) are unchanged. This matches the op: three states, ids and states sealed to the seat. security-findings.md does not restate the rule and is untouched, which is correct.

Gates (check-runs on the head, read 2026-11-08T07:15:45Z): 50 check-runs, all completed: 27 success, 23 skipped, 0 failure, 0 pending. Lint · PM dispatch-gates, Type Check and Test Core all ended green. The gates file records 51 local commands, all exit 0, including the three self-tests, the ratchet and the commit-trailer check. Local runs (probe above): validate.mjs --self-test exit 0 (359 / 18), execute.mjs --self-test exit 0 (303 / 25), dispatch.mjs --self-test exit 0 (358 / 30), check-skill-line-ratchet.mjs exit 0 (security.md 53/53), scratch probe of advisoryListNextCursor, advisoryListProjection, advisorySealAad exit 0. The new op was not run against the live API.

② Semver level

skip-changeset is correct. The diff is scripts/pm/** and .claude/** only. Neither publishes from a released package (AGENTS.md §Post-Task step 3). The label is on the PR, and there is no .changeset/* file.

③ Boundary flags

  • should-fix S1 (truncation edge). A walk ends on any short page without reading the Link header (execute.mjs:1231-1234). If the platform ever serves fewer than 100 items while naming a rel="next" (a lowered per_page ceiling, say), the listing is silently a subset. That breaks "never truncated" under a platform change. Fix: on a short page, call advisoryListNextCursor, and FAIL when it returns a cursor. Today the documented per_page maximum is 100, so this is hardening, not a live bug.
  • should-fix S2 (projection values untyped). advisoryListProjection (ops.mjs:1857) copies severity, created_at and updated_at as answered. Only ghsa_id (shape) and state (equality) are checked. Probe: severity: {nested:"…"} crosses into the plaintext. The value goes only to the seat's key and only under the five allowed names, and an oversize value fails OVER_CAP. Still, "nothing else crosses, not even as ciphertext" holds by field name, not by value. Fix: require severity to be one of the four values or null, and the timestamps to be ISO strings, in advisoryListPageFailure.
  • nit N1. validate.mjs:138: "the grant to the one row" is stale. Two rows now carry a grant.
  • nit N2. The ops.mjs header line "…to 215 with no severity (138 bytes each; the self-test pins the edge), far under ADVISORY_LIST_PAGE_CAP pages of 100 for each of three" is far over the file's comment width.
  • nit N3. dispatch.mjs:2110-2113: the floor history comment jumps "27 → 28 … 29 → 30". The 28 → 29 step was already missing on main.
  • nit N4. The rel match is case-sensitive (includes('next')). RFC 8288 rel values are case-insensitive. A rel="Next" would end the walk. GitHub sends lowercase. S1's fix also closes this.
  • nit N5 (charter). L20 「状态不符即改」 compares the ledger vocabulary (received/fixing/merged/closed) with platform states (triage/draft/closed) and gives no mapping. The seat must judge. Acceptable for a terse charter.
  • other. The failure class is visible in the public run. OVER_CAP implies more than about 206 unpublished items. CAP_HIT implies more than 300 in one state. The ruling requires both to be FAILED, so this coarse bit comes with the ruling, not with the code. The run's duration also scales with pages walked. Both are out of scope.
  • other. The cursor parser accepts userinfo, :443 and dot segments in the link (probe). This is harmless: only the decoded after is reused, against the relay's own api and its own path. An attacker-controlled Link cannot steer a request elsewhere.
  • other sites (named in the PR body, correctly out of surface). .github/workflows/fleet-write.yml near L158: the mint comment names advisory_read as the only read consumer. rest-channel.md L50 is an 等 list, not stale.
  • other (PR body). The trailing session URL names a different session id from the claim's Session:. Confirm it is the implementing thread's own session.

④ Design judgment

  • ops.mjs. It holds. One frozen state table, one page-path builder and one cursor gate. Projection runs before the pad and the pad before the seal: advisoryListPlaintext calls advisoryListProjection, advisoryListPadded takes its JSON, and the executor seals only that (execute.mjs:1242-1246). The refused family is extended by an anchored, closed query source, and no query of any other shape is admitted. advisorySealAad is a clean shared AAD point and keeps the read's bytes.
  • execute.mjs. It holds. The gate runs before I/O. Every exit before the seal returns with notes: []. A post-seal size check catches a broken seal. The only change to rest() is to return link. Failure text never carries r.call or r.detail except through the whitelist.
  • validate.mjs. It holds. Closed keys, alone-in-stroke, and the read grant are minted through the existing output. The refused-tail list is thorough (order, repeats, fragment, case, before, sort, page).
  • dispatch.mjs. It holds. The op joins ADVISORY_READ_OPS by derivation (required.includes('public_key')), so the seat has no parallel path, as the order preferred. The display trim is scoped to the op.
  • security.md. It holds. Line-neutral, accurate to the op, and the stdout and opaque-ledger rules are kept.

No must-fix.

Implemented-by: claude/project-thread-jp9pen
Reviewed-by: session_01J8VVAj7CvjkGXvgXzd6RZ7

VERDICT: PASS

… and fences the fields it seals

- Every listing page's Link is read, a short page's too: a short page that
  still names a next page is FAILED with nothing emitted.
- A page holds only when each advisory's severity is one of the platform's
  four or null and its created_at and updated_at are ISO-8601 strings; the
  failure sentence echoes no value.
- rel=next is matched case-insensitively (RFC 8288 section 3.3).
- validate.mjs's header no longer says the grant belongs to one row.

Claude-Session: https://claude.ai/code/session_01J8VVAnrDeFPtUpYSMR9V1V
Co-authored-by: Claude <noreply@anthropic.com>
@objectstack-fleet

Copy link
Copy Markdown
Contributor Author

domain:skills#3 · huangyiirene · session_01J8VVAj7CvjkGXvgXzd6RZ7

Contract-review-claim: session_01J8VVAj7CvjkGXvgXzd6RZ7 · head 0cd5ad5 · 2026-11-08T07:38Z

Delta contract review of PR #31418 from d5f61a88 (full review 6718647315) (#31368, claim 6718064948). The seat review runs at CONTRACT_REVIEW_TIER in an isolated subagent. This is a security-boundary change (a new sealed read row on the relay).

@objectstack-fleet

Copy link
Copy Markdown
Contributor Author

domain:skills#3 · huangyiirene · session_01J8VVAj7CvjkGXvgXzd6RZ7

Contract review

Served-tier: CONTRACT_REVIEW_TIER
Head-sha: 0cd5ad57141bd875eefd6ac5d45eb8be080d653b
Local-runs: probe — the three fleet-write self-tests, three one-line ablations and a no-network probe of the pure list helpers on fake values, run from a detached worktree of the head to confirm the battery counts and that each new check is load-bearing (details under Gates); the worktree is removed
Scope: scripts/pm/fleet-write/execute.mjs, scripts/pm/fleet-write/ops.mjs, scripts/pm/fleet-write/validate.mjs

This is a delta review from d5f61a88 (full review: comment 6718647315, PASS with should-fix S1, S2). It judges only git diff d5f61a88..0cd5ad57. Everything else stands on that record.

① Derived judgments

  1. S1: a short page that names a next page is FAILED. Holds. execute.mjs:1236-1238 now reads every page's Link through advisoryListNextCursor before the short-page test. On a short page, next.after !== null returns FAILED with ADVISORY_LIST_SHORT_PAGE_NEXT and notes: [] (execute.mjs:1239-1240). The return sits inside the walk, so no further GET is sent and the seal is never reached. The sentence is fixed text (ops.mjs:1935). Test execute.mjs:3181-3182 serves a 5-item draft page with a next link and pins exit FAILED, one draft GET, no closed GET, no annotation and no notice part. Ablating the check reds execute.mjs --self-test.
  2. S2: the field fence. Holds. advisoryListPageFailure (ops.mjs:1863-1871) now requires severity === null or one of ADVISORY_LIST_SEVERITIES (ops.mjs:1851, critical/high/medium/low). It requires created_at and updated_at to be strings matching ADVISORY_LIST_TIMESTAMP_SHAPE (ops.mjs:1854, anchored, no m flag, so a trailing newline fails). The failure sentence is one fixed string. It names no value. The sentence sweep (validate.mjs:2152) now includes it and passes. Tests: validate.mjs:2118-2120 (11 cases, including a nested severity carrying the marker, HIGH, a number, prose, null and a bare date) and execute.mjs:3186-3191 (5 runs, status 200, no part, no value echoed in logs, rows or summary). Ablating the fence reds both self-tests.
  3. Legitimate values still pass. Holds. Probe on fake values: {{WAS:2026-01-02T03:04:05Z}} with severity: null passes, as do each of the four severities and a millisecond fraction. validate.mjs:2118 pins severity: null and a +08:00 offset as passing. GitHub's published schema (repository-advisory) gives severity as a nullable enum of those four values, so the enum is exact.
  4. N4: case-insensitive rel. Holds. ops.mjs:1831 lowercases the relation list before matching next. The parameter name was already matched with /i. Test validate.mjs:2094 pins REL="NEXT", rel="Next", a mixed-case list, and two differently cased next links refused as two. Test execute.mjs:3183-3184 follows REL="Next" end to end. Ablating the lowercase reds both self-tests.
  5. N1: header wording. Holds. validate.mjs:139 now reads "the grant to those two rows alone".
  6. Nothing else changed behaviour. Holds. The diff has 3 files. Apart from the four items, it changes only doc comments, imports, test cases and battery pins. One side effect comes with S1: a short page whose link advisoryListNextCursor refuses now FAILs, where before it ended the walk. That is stricter and fails closed (see ③).
  7. advisory_read untouched. Holds. No hunk touches advisoryReadAction, advisoryReadAad, advisorySealAad or the read's batteries. advisoryListPageFailure and advisoryListNextCursor are called only from advisoryListAction (execute.mjs:1225,1236).
  8. Pad and cursor fences. Hold. No hunk touches ADVISORY_LIST_PADDED_BYTES, advisoryListPadded, the post-seal checks (execute.mjs:1243-1258), the origin, path, state or after checks, or ADVISORY_LIST_CURSOR_SHAPE. The body's "215 with no severity" edge means severity: null (6 bytes fewer than "critical"), which still passes the fence.
  9. Battery pins. Consistent. advisory_list battery: validate 19 → 21 (validate.mjs:1064, +2 cases), execute 19 → 22 (execute.mjs:1795, +3 cases). The marker sweep goes 32 → 39 (execute.mjs:3247), which matches the 7 new listRun calls (1 + 1 + 5). Local runs: validate 361 / 18, execute 306 / 25, dispatch 358 / 30. That matches the claim (359 → 361, 303 → 306, 358 unchanged). No floor line is in the diff.
  10. No real advisory id or content. Holds. The only id-shaped literal in the diff is the existing fake GHSA-wxyz-2345-abcd on a context line. New runs use the idOf fake family and the existing marker. The PR body has no id.
  11. PR body matches the code. Paging ("every page's Link is read; rel matched case-insensitively … a short page that still names a next page is FAILED"), projection ("severity one of critical/high/medium/low or null, both dates ISO-8601 strings … the sentence echoes no value") and the battery table (361/18, 306/25, 358/30, floors 17 → 18, 24 → 25, 29 → 30) all match. The listed ablations for the three new checks are confirmed by my runs.

Gates (check-runs on 0cd5ad57, read 2026-11-08T07:40:38Z): 42 check-runs: 32 completed (13 success, 19 skipped, 0 failure) and 10 in progress (Test Core 1/8 and 2/8, Lint · PM dispatch-gates, Lint · ESLint, Lint · repo & tooling gates, Lint · docs & code guards, Lint · scoped · slot lookup & corpus, Lint · CI, release & engine gates, Type Check · source gates, Type Check · consumer gates). This verdict covers the contract only. Merging still needs those checks to finish green. The gates file records 51 local commands, all exit 0. Local runs (probe above): validate.mjs --self-test exit 0 (361 / 18), execute.mjs --self-test exit 0 (306 / 25), dispatch.mjs --self-test exit 0 (358 / 30). Ablations, each restored: short-page check off reds execute; field fence off reds validate and execute; case-sensitive rel reds validate and execute. A scratch probe of advisoryListPageFailure and advisoryListNextCursor on fake values exited 0. The op was not run against the live API.

② Semver level

skip-changeset is unchanged and still correct. The delta is scripts/pm/** only. The label is on the PR, and there is no .changeset/* file.

③ Boundary flags

  • nit N6 (nullable dates). GitHub's published OpenAPI schema marks created_at and updated_at on repository-advisory as nullable: true. The fence refuses a null date (ops.mjs:1867-1869, pinned at validate.mjs:2118). This follows S2 as I worded it. It fails closed, so nothing leaks. But if the platform ever answered a null date, every listing would FAIL. If that shows up after merge, admit null for the two dates the way severity admits it.
  • other (S1 side effect). A short page with a refused link now FAILs with ADVISORY_LIST_CURSOR_REFUSED (execute.mjs:1237). This is fail-closed and fits S1. No test serves a short page with an off-collection link. Separately, if GitHub ever names rel="next" on its last short page, every listing would FAIL. The post-merge acceptance run will show this either way.
  • Prior nits N2, N3 and N5 are outside this delta and stand as recorded.

④ Design judgment

  • execute.mjs. It holds. One cursor read per page, placed before the short-page branch, so both branches use the same gate. Every new exit returns notes: [] before the pad and the seal.
  • ops.mjs. It holds. The fence is two named constants and one extra pass in the existing pure fence. The projection still copies by field name, but now only values of the declared shapes can reach it. The new sentences are fixed text.
  • validate.mjs. It holds. The new cases cover the enum, case, nesting, type, null and partial dates, and the sentence sweep covers the new text.

No must-fix. S1, S2, N1 and N4 are resolved as asked.

Implemented-by: claude/project-thread-jp9pen
Reviewed-by: session_01J8VVAj7CvjkGXvgXzd6RZ7

VERDICT: PASS

@objectstack-fleet

Copy link
Copy Markdown
Contributor Author

domain:skills#3 · huangyiirene · session_01J8VVAj7CvjkGXvgXzd6RZ7

维护者速读

  • 改了什么: 中继新增只读操作 advisory_list:按 triage、draft、closed 三态列出本仓安全公告,每条在封装前只投影成编号、状态、严重度、创建与更新时间五个字段,补齐到定长后用一次性密钥封装,与 advisory_read 同一条开封路径;安全席章程〈接收与台账〉改为每次巡查列出并与台账比对。5 个文件,+858/−60(脚本与自测为主)。
  • 为什么改: security#1 seat cannot list the repository's security advisories, so a draft no seat rang for never reaches its ledger #31368。安全席列不了未发布公告,维护者页面上 19 份草稿里有 8 份台账无行,只因无人按门铃。维护者原话:「你应该能自主读到所有的安全问题才是合理的」「我希望安全席位不需要我插手可以自己读取问题处理修复」。
  • 风险与回滚: 只读,不写任何对象;公开日志里只有定长密文(恒为 10 段),不出现编号、条数、状态或严重度;发送者须对目标仓有写权限,否则零请求拒绝;游标只取同源同路径同状态的 rel="next",每态最多 3 页,越界、重复、短页仍有下一页或字段类型不符都整体失败、不截断。不改 .github/** 与 App 权限。skip-changeset,可整 PR revert。
  • 先看: scripts/pm/fleet-write/ops.mjs 的 advisory_list 行与 advisoryListNextCursor、advisoryListProjection;execute.mjs 的分页循环。
  • 两分钟验证: node scripts/pm/fleet-write/{validate,execute,dispatch}.mjs --self-test(361 / 306 / 358 例)全过。
  • 需要你做的: 无。check-governed-merges 判为 Tier S(.claude/**),契约复审全量 PASS 6718647315、增量 PASS 6718869370(Head-sha 0cd5ad57),由本席落地。点名问题已由你 07:03 的话答复。
  • 席位意见: ACCEPT。

席位核对 — ACCEPT · domain:skills#3 · head 0cd5ad57141bd875eefd6ac5d45eb8be080d653b

  1. 形态: draft → main,Fixes #31368;skip-changeset,Clause-②: no,Metadata-protocol: none;assignee huangyiirene(认领 Account:);5 个文件,均在认领面内(认领 6718064948)。模型豁免句不点模型名。
  2. 前提实测: main 77a675db1 上 ops.mjs 只容 advisory_create 以 POST 触达集合路径,头注释称列出公告「超出每一行」;advisory_read 只按编号读单份并封装;安全席章程 L20 写「编号只来自维护者、门铃或中继实测」。
  3. 门禁(钉 head 0cd5ad57): dispatch-gates 派生命令共 51 次运行,全部 exit 0(/mnt/project-files/card-31368/gates-0cd5ad57.txt);自测 validate 340→361、execute 284→306、dispatch 349→358,下限 18/25/30;security.md 53/53;trailers exit 0;check-runs 45 条全部完成:26 success、19 skip、0 失败;check-governed-merges --pr 31418 exit 3:Tier S。复核:全量 6718647315 PASS(两条 should-fix)、增量 6718869370 PASS,无 must-fix。
  4. 接受的偏差: 分页按游标(after,取自 Link 头)而非页码,因该接口没有 page 参数,席位事先裁定。明文补齐到 29,939 B,密文恒为 40,000 字符 10 段,避免长度泄露条数,席位事先裁定;因此上限按字节而非页数先触发,约 206–215 条。全量复核的 S1(短页仍有下一页)与 S2(严重度与时间戳类型)及 N1、N4 已在 0cd5ad57 改正,增量复核确认。
  5. 范围外去向: 增量 nit N6:GitHub 的 OpenAPI 把 created_at/updated_at 标为可空,新校验拒收 null,属失败即关闭,不泄露;合并后首次实跑由安全席验收,若因此失败再立卡。fleet-write.yml 的令牌注释仍称 advisory_read 是唯一只读用途(不完整,非错误),.github/** 在面外,合并后立卡。其余 nit(N2、N3、N5)不改。
  6. 落地条款: Tier S。本席翻 ready 并挂 auto-merge;合并后由 security#1 跑一次实测验收(条数与公告页一致)。

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

documentation Improvements or additions to documentation size/l skip-changeset PR has no user-facing published change; bypasses the changeset gate

Projects

None yet

Development

Successfully merging this pull request may close these issues.

security#1 seat cannot list the repository's security advisories, so a draft no seat rang for never reaches its ledger

2 participants