Skip to content

CONTRIBUTING: describe reviewing source: matched candidates - #28

Merged
andrew merged 2 commits into
mainfrom
contributing-matched-review
Jul 28, 2026
Merged

CONTRIBUTING: describe reviewing source: matched candidates#28
andrew merged 2 commits into
mainfrom
contributing-matched-review

Conversation

@andrew

@andrew andrew commented Jul 28, 2026

Copy link
Copy Markdown
Member

brew advisory-match (Homebrew/brew#23329) will produce automated PRs adding records with database_specific.source: "matched". This adds a section explaining what the strategy/confidence/upstream_evidence and range_state/upstream_fixed_in/resource fields mean, and a review checklist covering: verifying the evidence points at this formula's actual upstream, ruling out distro-specific CVEs, spot-checking the fixed boundary against homebrew-core history, the known false-positive sources found during calibration (stale CPANSA ranges, conflicting OSV alias ranges), and not overwriting source: generated records.

Can merge independently of #27; both are prep for the nightly ingest workflow which needs Homebrew/brew#23329 in a release first.

brew advisory-match (Homebrew/brew#23329) produces automated PRs adding
records with database_specific.source: matched. Document what the
strategy/confidence/upstream_evidence and range_state/upstream_fixed_in/
resource fields mean and give a review checklist: verify the evidence
points at this formula's actual upstream, rule out distro-specific CVEs,
spot-check the fixed boundary against homebrew-core history, and handle
the known false-positive sources (stale CPANSA ranges, conflicting OSV
alias ranges). Note that matched records must not overwrite
source: generated ones.
Copilot AI review requested due to automatic review settings July 28, 2026 15:04

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Updates contributor documentation to support incoming automated PRs produced by brew advisory-match, clarifying how to review and validate “matched” candidate advisory records before merging.

Changes:

  • Describes the new third advisory source: database_specific.source: "matched" candidate records.
  • Documents the meaning of strategy/confidence/upstream_evidence and range_state/upstream_fixed_in/resource fields.
  • Adds a reviewer checklist for common false positives and boundary verification against homebrew-core history.
Comments suppressed due to low confidence (1)

CONTRIBUTING.md:56

  • Similarly, inline examples like range_state: "fixed" / range_state: "affected" look like YAML rather than JSON. Since this section is documenting JSON keys/values, prefer JSON-style "range_state": "..." for clarity.
- If `range_state: "fixed"`, the `fixed` boundary in `ranges` is the `pkg_version` at which Homebrew first shipped the fix. `brew advisory-match` derives this by walking `homebrew-core` history; spot-check it against `git log -p -- Formula/<letter>/<name>.rb` in a `homebrew-core` checkout and correct it in the PR if wrong. The corrected value is preserved on subsequent regenerations.
- If `range_state: "affected"` with a `resource`, `brew info <formula> --json=v2 | jq '.formulae[0].resources[] | select(.name == "<resource>") | .version'` confirms the pinned resource version is below `upstream_fixed_in`. Known false-positive sources are stale CPANSA ranges and OSV records where one alias (often a PYSEC id) has an open-ended range while another has a bounded one.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread CONTRIBUTING.md Outdated
Comment thread CONTRIBUTING.md Outdated
@andrew
andrew requested a review from p-linnane July 28, 2026 15:22

@p-linnane p-linnane left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice!

@andrew
andrew merged commit 44336f4 into main Jul 28, 2026
5 checks passed
@andrew
andrew deleted the contributing-matched-review branch July 28, 2026 15:28
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.

3 participants