Repository navigation
Label whole-project security findings by class - #2219
Merged
Merged
Conversation
Add a Findings format to whole-project-report.md (one finding per line, `[class] path:line severity: text`, fixed class vocabulary, one primary cite per finding). report_contract_lint.py gains finding-no-class and finding-multi-cite, accepts `path:12,15,20` line lists and `-` (stdin), and keeps bad-citation for bare names. security-review-mode.md pipes the draft through the linter before emitting. Tests: 34/34 Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Tests: 34/34 Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
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.
Security audit reports now label each finding with a class and one primary
path:line, and the report linter enforces it. This fixes the dominant G6 set1 failure: reports cited bare file names and carried no class, so real findings could not be matched or classified.What changes
whole-project-report.mddefines a## Findingsline format:[<class>] <repo-relative path>:<line> <severity>: <text>, with a fixed 18-class vocabulary. Evidence cites go afterevidence:. A chain finding cites its end-state line as the primary.report_contract_lint.pygains two rules:finding-no-class: missing or unknown class label.finding-multi-cite: a second real file cite beforeevidence:.-(stdin) report and acceptspath:12,15,20line lists. Prose, indented continuation lines and attack-path or chain subsections are not linted.security-review-mode.mdstep 5 writes the Findings section and pipes the draft through the linter before emitting.Review: an independent reviewer found 2 🔴 and 5 🟡, all fixed in this commit:
host:porttext was read as a second cite.a.py,2fa.py.A re-review came back clean. Known gap: a second cite to a file that does not exist is not flagged as a multi-cite.
Checks run locally: pre-commit green,
run-ci-tests.sh --affectedexit 0,test_report_contract_lint.py34/34.🤖 Generated with Claude Code