Skip to content

feat(scanner): Phase 2 built-in scanner hardening & SARIF v2.1.0 export - #6

Open
huangji6693-max wants to merge 1 commit into
BreachDirect:mainfrom
huangji6693-max:feat/phase2-scanner-hardening-sarif-1
Open

huangji6693-max wants to merge 1 commit into
BreachDirect:mainfrom
huangji6693-max:feat/phase2-scanner-hardening-sarif-1

Conversation

@huangji6693-max

@huangji6693-max huangji6693-max commented Oct 27, 2026 •

Copy link
Copy Markdown

Summary

Implements Phase 2 built-in scanner hardening and SARIF v2.1.0 export:

  • Expanded OWASP Top 10 Probes (app/services/owasp_top10.py, app/services/owasp.py): Added A04:2021 — Insecure Design (check_insecure_design) and A08:2021 — Software and Data Integrity Failures (check_subresource_integrity) probes, and added baseline response comparison in fuzz_url_parameters to suppress false-positive SQL error matches on pages that naturally mention SQL terms.
  • False-Positive Tuning & Severity Calibration (app/services/finding_utils.py): Added filter_false_positives, calibrate_finding_severity, and deduplicate_findings to filter HTML-entity-encoded XSS reflections, calibrate verified injection findings, and keep duplicate rates well below 20%.
  • Parameter Fuzz Budget Profiles (app/config.py): Added fuzz_profile (quick / standard / deep) and Settings.get_fuzz_budget().
  • SARIF v2.1.0 Export (app/services/sarif_exporter.py, app/routers/scans.py): Added GET /api/scans/{id}/report/sarif returning GitHub Code Scanning compatible SARIF v2.1.0 JSON.
  • Regression Fixtures & Documentation (tests/test_scanner_phase2.py, docs/thesis_chapter4_findings.md, README.md): Added DVWA Low (>= 15 findings, < 20% duplicate rate) and OWASP Juice Shop regression test suites, documented Chapter 4 benchmark finding counts, and updated README.md with SARIF usage examples.

Verification

  • pytest tests/ -v: 18 passed
  • ruff check app tests: All checks passed
  • bandit -r app -c bandit.yaml -ll -q: Clean

Closes #1


Payout Wallets

  • Stellar (XLM / USDC): GBYWLISGOUWQ43VQEGXX6KRGDZ3CKAFFK3JXVLXKDO5TIFJUJ3OHJYOZ
  • EVM / Base USDC: 0x380C97bcbcAEf29DAc2d0ba7E180F1b4A7F38fdd
  • Solana (USDC / SOL): AyXYaA9Nf4z5fpLKY6DmubWe6D2qveMd79w8pEDNHcDw

… v2.1.0 export

- Expand OWASP Top 10 coverage in app/services/owasp_top10.py with A04 Insecure Design and A08 Subresource Integrity probes plus baseline SQLi false-positive suppression
- Add false-positive filtering, severity calibration, and cross-phase deduplication in app/services/finding_utils.py
- Add quick/standard/deep parameter fuzz budget profiles in app/config.py
- Implement SARIF v2.1.0 exporter and GET /api/scans/{id}/report/sarif endpoint
- Add DVWA Low and OWASP Juice Shop regression fixture tests and Chapter 4 benchmark documentation

Closes BreachDirect#1
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.

Phase 2: Built-in Scanner Hardening & SARIF Export

1 participant