Skip to content

The advisory watch checks every payload and SBOM component it can, and names what it cannot (REQ-ADVISORYWATCH-002) - #302

Merged
avrabe merged 6 commits into
mainfrom
feat/advisory-watch-coverage
Oct 29, 2026
Merged

avrabe merged 6 commits into
mainfrom
feat/advisory-watch-coverage

Conversation

@avrabe

@avrabe avrabe commented Oct 29, 2026

Copy link
Copy Markdown
Contributor

Implements REQ-ADVISORYWATCH-002 clauses 2–5. Clause 1, the scheduled watcher in each layers repository, moved to REQ-ADVISORYWATCH-003 for v0.45.0 under the maintainer's v0.44.0 trim. This PR also carries REQ-MIRROR-002 (v0.45.0, #301) and the maintainer's demotion of REQ-MIRROR-001 to implemented, because its verified evidence never reached a fetch.

Per clause

  • (2) A crate payload is checked against RustSec by its own crate name and version, not only through its repository's GitHub advisories.
  • (3) Every SBOM component is checked or reported unchecked with its reason. Nested components are walked. The ecosystem is decided by purl type, and only pkg:cargo is looked up, using the crate name from the purl. An npm serde can never match a cargo serde advisory. A component that has no version, no purl, an unreadable purl, or a non-cargo ecosystem is reported with that reason.
  • (4) Payloads that share a repo and version but come from different releases each get their own SBOM read.
  • (5) GitHub advisories, as the maintainer decided on 2026-10-29:
    • An advisory naming the payload's own package is a certain finding.
    • One that names only sibling packages of the same repository, with a range covering the version, is a qualified finding: qualified: names wasmtime-wasi from the same repository (bytecodealliance/wasmtime); affects this binary if it embeds that crate. The qualifier goes in the existing detection field, so the signed schema is unchanged and the two kinds stay machine-distinguishable.
    • A sibling whose range misses the version is not a finding.
    • If any payload matches an advisory exactly, the advisory is certain for the layer. Understating a security finding is the worse error.

The case that drove clause 5

As first written, clause 5 dropped GHSA-m9f7-9w4p-gv38, the high-severity wasmtime sandbox escape behind REQ-ADVISORYWATCH-001. That advisory names wasmtime-wasi, a crate compiled into the wasmtime binary. It is back as a qualified finding. The wasmtime 49.0.1 fixture gives 23 findings: 15 certain, 8 qualified, and the test asserts both counts.

Evidence

  • Tests failed first: one negative control per clause, plus the wasmtime counts and the exact-wins rule. The red output was recorded before each implementation.
  • Locally on 10cda4c: fmt and clippy -D warnings are clean, cargo test --workspace -j 2 exits 0 with 38 suites, and rivet validate, the trace gate and claim-check all pass.
  • Unfiltered mutants, --no-shuffle -j 2 --timeout 120, with the repo config:
    • advisorywatch.rs and statusdraft.rs: 205 tested, 180 caught, 25 unviable, 0 missed.
    • After the exact-wins fix, advisorywatch.rs again: 177 tested, 154 caught, 23 unviable, 0 missed.

The implementation was delegated to a subagent and reviewed. Review changed the multi-payload rule to exact-wins, and the maintainer decided clause 5.

🤖 Generated with Claude Code

https://claude.ai/code/session_019TNtfRjLNhEz82G2ggeeNu

avrabe and others added 6 commits October 29, 2026 18:48
…y SBOM component and matches only the package that names the payload (REQ-ADVISORYWATCH-002 clauses 2-5)

- A kind=crate payload is looked up in RustSec by its own crate name and version.
- Every SBOM component is checked or reported unchecked with its reason: no
  version, no or unreadable purl, an ecosystem RustSec does not cover. The
  ecosystem is the purl type, never the bare name; nested components are walked.
- Payloads are de-duplicated on release and tool as well as repo and version,
  so each release's own SBOM is read.
- A GitHub advisory is matched against the package range that names the
  payload; advisories naming only other packages are listed as unchecked.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019TNtfRjLNhEz82G2ggeeNu
… qualified finding, not an unchecked gap (REQ-ADVISORYWATCH-002 clause 5)

The package range that names the payload is certain. An advisory naming only
other packages of the same repository, with a range covering the payload's
version, stays a finding and carries a machine-readable qualifier in the
line-status entry's detection field. A sibling whose range misses the version
is not a finding. The wasmtime fixture is back to 23 findings: 15 certain,
8 qualified, including GHSA-m9f7-9w4p-gv38 (wasmtime-wasi).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019TNtfRjLNhEz82G2ggeeNu
…for the layer

Reviewed from e98e003. The subagent kept an advisory qualified if ANY payload
matched it only as a sibling package. That understates a finding some payload
matched exactly, and the maintainer chose the side where a sandbox escape is
not missed. Test changed first and failed.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019TNtfRjLNhEz82G2ggeeNu
…ATCH-003)

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019TNtfRjLNhEz82G2ggeeNu
…ached a fetch (#301)

Decided by the maintainer on 2026-10-29. It returns to verified with
REQ-MIRROR-002's system test in v0.45.0.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019TNtfRjLNhEz82G2ggeeNu
@avrabe
avrabe merged commit 04ca5d9 into main Oct 29, 2026
41 checks passed
@avrabe
avrabe deleted the feat/advisory-watch-coverage branch October 29, 2026 20:18
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant