feat(enrichment): SBOM provenance & integrity-attestation analyzer (#…#1629
Merged
JSONbored merged 7 commits intoJun 29, 2026
Merged
Conversation
…SONbored#1518) Adds a new `provenance` analyzer to the review-enrichment service (REES) with two categories of finding: 1. **Attestation checks** — newly-added npm and PyPI dependencies are queried against the npm registry attestations API and the PyPI simple repository JSON API (PEP 740) for published SLSA/sigstore provenance. A package lacking attestations was not built through a verifiable CI pipeline and is flagged as a supply-chain integrity risk the no-checkout reviewer cannot detect on their own. 2. **Binary and vendored file detection** — files added by the PR with binary extensions (.exe, .dll, .so, .jar, .wasm, etc.), vendored paths (vendor/, node_modules/, third-party/), or minified bundles (.min.js, .min.css) are flagged as artifacts without reviewable source. Pure structural scan, no network. Both categories are rendered in the `promptSection` under distinct headings and appear in the structured `findings.provenance` array. The analyzer runs in parallel with the existing seven analyzers under the shared time budget and degrades safely on network errors. Validated: npm run build && node --test in review-enrichment/ (77/77 pass, provenance.js 98.31% branch coverage); npm audit clean; 0 new typecheck or test failures introduced in the main workspace. Closes JSONbored#1518
|
Warning 🟨🟨🟨🟨🟨🟨🟨🟨🟨🟨🟨🟨 ⏸️ Gittensory review — held for maintainer review
⏸️ Held for maintainer review — Large change — held for manual review
Nits — 2 non-blocking
Review context
Contributor next steps
Signal definitions
🟩 Safe / merged · 🟦 Advisory · 🟨 Held for review · 🟥 Blocked / closed 💰 Earn for open-source contributions like this. Gittensor lets GitHub contributors earn for the work they already do — register to start earning →. Checked by Gittensory, a quiet PR intelligence layer for OSS maintainers.
|
24 tasks
Signed-off-by: dale053 <[email protected]>
24 tasks
…ocks in renderBrief
…ver false branches
Signed-off-by: dale053 <[email protected]>
4 tasks
JSONbored
approved these changes
Jun 29, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
provenanceanalyzer to the review-enrichment service (REES) that detects two classes of supply-chain integrity risk the no-checkout reviewer cannot verify on their own:.exe,.dll,.so,.jar,.wasm, etc.), vendored paths (vendor/,node_modules/,third-party/), or minified bundles (.min.js,.min.css) are flagged as artifacts without auditable source.Both categories are rendered in the
promptSectionunder distinct headings and appear in the structuredfindings.provenancearray. The analyzer runs in parallel with the existing seven analyzers under the shared time budget, degrades safely on network errors (fail-safe: never flags when the check cannot be completed), and is bounded to 20 attestation round-trips and 30 total findings per brief.Closes #1518
Scope
type(scope): short summaryConventional Commit format, for examplefix(api): restore profile access checks.CONTRIBUTING.mdand does not reintroduce GitHub Pages, VitePress,site/, orCNAME.Validation
git diff --checknpm run actionlintnpm run typechecknpm run test:coveragelocally;codecov/patchrequires ≥97% coverage of the lines AND branches you changed (aim for 98%+ on your diff so CI variance does not fail near the threshold). Global coverage is a non-blocking trend with a loose 90% backstop, not the gate.npm run test:workersnpm run build:mcpnpm run test:mcp-packnpm run ui:openapi:checknpm run ui:lintnpm run ui:typechecknpm run ui:buildnpm audit --audit-level=moderateIf any required check was skipped, explain why:
npm run typecheckandnpm run ui:typecheckreport 28 and 5 pre-existing errors respectively (missing optional self-host packages:pg,ioredis,@sentry/node,@cloudflare/puppeteer,@testing-library/react). These errors are identical onmainbefore this PR and are unrelated to the changes here. Zero new type errors introduced.review-enrichment/which is outside the main vitest coverage scope (src/**) and the Codecovincludepath. The enrichment test suite (node --testinreview-enrichment/) runs 77 tests, all passing, withprovenance.jsat 98.31% branch coverage.Safety
UI Evidencesection below with JPG/JPEG or PNG screenshots. — N/A: no visible UI changes.UI Evidence
N/A — no visible UI, frontend, docs, or extension changes.
Notes
true(attested / safe) so the enrichment brief never generates false positives from infrastructure noise.https://registry.npmjs.org/-/npm/v1/attestations/<name>@<version>. A 404 is the unambiguous "no attestation" signal; any other non-ok response is treated as a failed check and suppressed.Accept: application/vnd.pypi.simple.v1+jsonagainst the simple repository API (PEP 740). Only the specific version's distribution files are examined; if no file for that version is found, the check is suppressed (not flagged).