docs: Update README with supply chain protection features#18
docs: Update README with supply chain protection features#18ProduktEntdecker wants to merge 5 commits intomainfrom
Conversation
Add documentation for version quarantine (72h), new package detection (7d), and low download check (<100/week). Reference the Axios supply chain attack as motivation. Update decision logic table and limitations. Closes #17 Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
WalkthroughDie README beschreibt jetzt kombinierte CVE‑ und Supply‑Chain‑Prüfungen vor Installationen, zeigt OSV‑ und Registry‑Metadaten‑Prüfungen parallel im Ablauf und ergänzt eine quellenbewusste Entscheidungslogik sowie erweiterte Limitierungen. (≤50 Wörter) Changes
Sequence Diagram(s)sequenceDiagram
participant User
participant PatchPilot
participant OSV
participant Registry
participant DecisionEngine
User->>PatchPilot: Installationsanfrage
PatchPilot->>OSV: CVE‑Abfrage
PatchPilot->>Registry: Paket‑Metadaten anfordern
par Parallel evaluation
OSV-->>PatchPilot: CVE‑Ergebnisse
Registry-->>PatchPilot: Supply‑Chain‑Signale
end
PatchPilot->>DecisionEngine: CVE + Supply‑Chain Ergebnisse
DecisionEngine-->>PatchPilot: Aktion (block / allow with warn / ask)
PatchPilot-->>User: Aktion / Ergebnis anzeigen
Estimated code review effort🎯 1 (Trivial) | ⏱️ ~3 Minuten 🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches🧪 Generate unit tests (beta)
Comment |
There was a problem hiding this comment.
Actionable comments posted: 3
🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.
Inline comments:
In `@README.md`:
- Line 14: Die README enthält ein fenced code block ohne Language-Tag (MD040) —
locate the fenced block that contains the sample lines starting with You:
"install lodash for me" and Claude: "npm install lodash@4.17.0" and add a
language identifier (e.g., change the opening ``` to ```text) so markdownlint
passes and syntax highlighting/rendering is correct.
- Line 32: Die README-Angabe "New Package Detection" (< 7 days old) stimmt nicht
mit der Implementierung in src/registry.ts (die aktuell < 30 days verwendet)
überein; bitte synchronisieren: entweder aktualisiere die README-Zeile für "New
Package Detection" auf "< 30 days old" oder ändere den Schwellenwert in
src/registry.ts (die Konstante/Prüfung, z.B. NEW_PACKAGE_THRESHOLD / die
Altersprüfung in src/registry.ts) auf 7 Tage, und stelle sicher, dass Tests/Docs
entsprechend angepasst werden.
- Line 122: Die README-Dokumentation ist falsch: die Tabelle sagt „MODERATE or
LOW → Allow“, aber in src/decision.ts (prüfe die Funktion/Mapping, z.B.
mapCveSeverityToDecision oder getDecisionForCVE) wird MODERATE zu "ask" und nur
LOW zu "allow". Fix: aktualisiere die README.md-Tabelle (die Zeile mit
CVE/MODERATE/LOW) so dass MODERATE klar als "Ask" (oder entsprechendem
Entscheidungstext) und LOW als "Allow" steht, sodass die Dokumentation exakt das
Verhalten in src/decision.ts widerspiegelt.
🪄 Autofix (Beta)
Fix all unresolved CodeRabbit comments on this PR:
- Push a commit to this branch (recommended)
- Create a new PR with the fixes
| | Check | What it catches | Threshold | | ||
| |-------|----------------|-----------| | ||
| | **Version Quarantine** | Recently published versions — suggests previous stable release | < 72 hours old | | ||
| | **New Package Detection** | Brand-new packages with no history | < 7 days old | |
There was a problem hiding this comment.
Schwellenwert für „New Package Detection“ stimmt nicht mit dem Code überein.
Auf Line 32 steht < 7 days old, aber src/registry.ts nutzt aktuell < 30 days. Diese Diskrepanz macht die Doku unzuverlässig.
Vorgeschlagene Korrektur
-| **New Package Detection** | Brand-new packages with no history | < 7 days old |
+| **New Package Detection** | Brand-new packages with no history | < 30 days old |📝 Committable suggestion
‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.
| | **New Package Detection** | Brand-new packages with no history | < 7 days old | | |
| | **New Package Detection** | Brand-new packages with no history | < 30 days old | |
🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.
In `@README.md` at line 32, Die README-Angabe "New Package Detection" (< 7 days
old) stimmt nicht mit der Implementierung in src/registry.ts (die aktuell < 30
days verwendet) überein; bitte synchronisieren: entweder aktualisiere die
README-Zeile für "New Package Detection" auf "< 30 days old" oder ändere den
Schwellenwert in src/registry.ts (die Konstante/Prüfung, z.B.
NEW_PACKAGE_THRESHOLD / die Altersprüfung in src/registry.ts) auf 7 Tage, und
stelle sicher, dass Tests/Docs entsprechend angepasst werden.
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
There was a problem hiding this comment.
♻️ Duplicate comments (1)
README.md (1)
14-23:⚠️ Potential issue | 🟡 MinorCodeblock mit Sprachkennung versehen.
Der fenced block startet ohne Language-Tag. Das triggert
MD040und sollte auf z. B.textgesetzt werden.Vorgeschlagene Korrektur
-``` +```text You: "install lodash for me" ↓ Claude: "npm install lodash@4.17.0" ↓ PatchPilot: ┌─ OSV database (known CVEs) └─ Registry metadata (supply chain signals) ↓ BLOCKED: 4 vulnerabilities found (1 critical, 3 high)</details> <details> <summary>🤖 Prompt for AI Agents</summary>Verify each finding against the current code and only fix it if needed.
In
@README.mdaround lines 14 - 23, Der fenced codeblock im README fehlt ein
Language-Tag (verursacht MD040); öffne den betroffenen triple-backtick-Block im
README.md und füge das passende Tag (z. B. text) direkt nach den Backticks hinzu
(text), sodass der Block wie im Vorschlag markiert ist; überprüfe anschliessend, dass der Blockbeginn exakt mittext übereinstimmt und
speichere die Datei.</details> </blockquote></details> </blockquote></details> <details> <summary>🤖 Prompt for all review comments with AI agents</summary>Verify each finding against the current code and only fix it if needed.
Duplicate comments:
In@README.md:
- Around line 14-23: Der fenced codeblock im README fehlt ein Language-Tag
(verursacht MD040); öffne den betroffenen triple-backtick-Block im README.md und
füge das passende Tag (z. B. text) direkt nach den Backticks hinzu (text), sodass der Block wie im Vorschlag markiert ist; überprüfe anschliessend, dass der Blockbeginn exakt mittext übereinstimmt und speichere die Datei.</details> --- <details> <summary>ℹ️ Review info</summary> <details> <summary>⚙️ Run configuration</summary> **Configuration used**: Organization UI **Review profile**: ASSERTIVE **Plan**: Pro **Run ID**: `636d7d45-267c-44a6-9fbb-05e7859d22e7` </details> <details> <summary>📥 Commits</summary> Reviewing files that changed from the base of the PR and between d3f35592a7fe9662d227cd83eee510d3f6d30aee and d212d62affb0521219d4ee64d185955305208666. </details> <details> <summary>📒 Files selected for processing (1)</summary> * `README.md` </details> </details> <!-- This is an auto-generated comment by CodeRabbit for review status -->
- Add language tag to fenced code block (MD040) - Fix decision table: MODERATE → ask (not allow), matches decision.ts - Note: 7-day threshold for new package detection is correct per code Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
There was a problem hiding this comment.
Actionable comments posted: 1
🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.
Inline comments:
In `@README.md`:
- Line 127: Die Formulierung "zero additional latency" in der Zeile mit "Supply
chain checks run in parallel with CVE checks (zero additional latency) and
fail-open — if the registry is unreachable, installs proceed normally." ist zu
absolut; ersetze sie durch eine präzisere Formulierung wie "no noticeable
additional latency", "minimal additional latency" oder "negligible additional
latency" und behalte den Hinweis auf parallele Ausführung und
fail-open-Verhalten bei, so dass der Satz klarstellt, dass die Checks parallel
laufen und in der Praxis meist keine merkliche Verzögerung erzeugen, aber
Netzwerklatenzen/Timeouts weiterhin Einfluss haben können.
🪄 Autofix (Beta)
Fix all unresolved CodeRabbit comments on this PR:
- Push a commit to this branch (recommended)
- Create a new PR with the fixes
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
There was a problem hiding this comment.
♻️ Duplicate comments (1)
README.md (1)
32-32:⚠️ Potential issue | 🟠 MajorSchwellwert für „New Package Detection“ weiterhin inkonsistent.
Auf Line 32 steht weiterhin
< 7 days old, obwohl zuvor bereits die Abweichung zur Implementierung (src/registry.tsmit< 30 days) gemeldet wurde. Bitte Doku und Code auf denselben Wert bringen.Vorgeschlagene README-Korrektur
-| **New Package Detection** | Brand-new packages with no history | < 7 days old | +| **New Package Detection** | Brand-new packages with no history | < 30 days old |🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed. In `@README.md` at line 32, Die README-Zeile für "New Package Detection" zeigt "< 7 days old", ist aber inkonsistent mit der Logik in src/registry.ts, die "< 30 days" verwendet; vereinheitliche den Schwellenwert, indem du entweder die README-Tabelle auf "< 30 days old" anpasst oder die Implementierung in src/registry.ts (z. B. die Konstante/Variable, Funktion oder Bedingung, die das 30-Tage-Limit definiert) auf 7 Tage änderst, und führe beide Orte (README und die betreffende Stelle in src/registry.ts) so zusammen, dass sie denselben Wert verwenden.
🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.
Duplicate comments:
In `@README.md`:
- Line 32: Die README-Zeile für "New Package Detection" zeigt "< 7 days old",
ist aber inkonsistent mit der Logik in src/registry.ts, die "< 30 days"
verwendet; vereinheitliche den Schwellenwert, indem du entweder die
README-Tabelle auf "< 30 days old" anpasst oder die Implementierung in
src/registry.ts (z. B. die Konstante/Variable, Funktion oder Bedingung, die das
30-Tage-Limit definiert) auf 7 Tage änderst, und führe beide Orte (README und
die betreffende Stelle in src/registry.ts) so zusammen, dass sie denselben Wert
verwenden.
Summary
Closes #17
🤖 Generated with Claude Code
Summary by CodeRabbit