Skip to content

feat: add DeepSec security-scan tracer bullet (COD-450) - #6

Merged
shivros merged 1 commit into
mainfrom
runner/COD-450-deepsec-security-scan
Sep 2, 2026
Merged

feat: add DeepSec security-scan tracer bullet (COD-450)#6
shivros merged 1 commit into
mainfrom
runner/COD-450-deepsec-security-scan

Conversation

@shivros

@shivros shivros commented Aug 29, 2026

Copy link
Copy Markdown
Contributor

Summary

Implements COD-450 tasks 2–7: a fixture-backed examples/security-scan consumer that explicitly projects run_security_scan to CLI, HTTP, and MCP.

  • Declares POST /security/scans with required target and optional profile.
  • Keeps scanner selection, typed validation, dispatch, and public error mapping consumer-owned; Hydra remains scanner- and vendor-neutral.
  • The checked-in fixture accepts only fixture:demo-repo with the baseline profile and never executes caller input.
  • Commits generated artifacts and checks both examples for codegen drift in CI.
  • Documents the future environment-only DEEPSEC_ENDPOINT/DEEPSEC_TOKEN boundary without adding a real client.

Validation

cargo build --all-targets
cargo test --all-targets
cargo clippy --all-targets -- -D warnings
cargo fmt --all -- --check
cd examples/notes && cargo run -p hydra-codegen --bin hydra-codegen -- check
cd examples/security-scan && cargo run -p hydra-codegen --bin hydra-codegen -- check

All passed. The review panel identified strict request-validation and fixture-bypass issues; those were fixed before this PR was opened. Note: generated CLI omission is represented as JSON null, so profile: null is treated as the documented omitted/baseline profile.

Closes COD-450.

@shivros

shivros commented Aug 29, 2026

Copy link
Copy Markdown
Contributor Author

🤖 Automated Review Panel

GPT-5.5 (openai/gpt-5.5)

Initial review found two blocking correctness gaps: the fixture adapter could be bypassed with an invalid typed request, and deserialization admitted undeclared fields. It also requested stronger redaction coverage.

Fixed before opening this PR:

  • the fixture now independently rejects any target/profile outside its closed contract;
  • ScanRequest fields are private so external callers cannot construct invalid requests;
  • request deserialization uses deny_unknown_fields, with a regression proving a sentinel extra field is rejected before adapter invocation;
  • generated CLI represents omitted optional profile as JSON null; the consumer treats that as documented baseline omission so the generated CLI remains functional.

No remaining blocking issue identified after the fixes and full gate rerun.


Gemini 3 Flash (google/gemini-3-flash-preview)

The review confirmed the explicit three-surface operation, consumer-owned dispatch/adapter boundary, deterministic fixture, generated artifacts, and documentation align with the tracer-bullet contract. It found unknown request fields were silently accepted; this was fixed before PR creation with strict request deserialization and a regression test.

No remaining blocking issue identified after the fixes and full gate rerun.

@shivros
shivros marked this pull request as ready for review August 30, 2026 22:06
@shivros
shivros merged commit 4989b49 into main Sep 2, 2026
2 checks passed
@shivros
shivros deleted the runner/COD-450-deepsec-security-scan branch September 2, 2026 00:27
shivros added a commit that referenced this pull request Sep 11, 2026
)

Align workspace.package.version 0.1.0 -> 0.2.2 across all five members
(via inheritance), refresh Cargo.lock package records only (no registry
changes), and document the release/versioning policy: immutable
historical tags, honest #6-#8 reference/metadata summary, git-tag
consumer pins with regen requirement, and an explicit proposed/unpublished
marker until the separate publication task lands.

No tag, release, or publication is created by this change.
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.

1 participant