feat(report): embed repro block in JSON findings (POST_V01 Item 4)#33
Merged
Conversation
Add model.FindingRepro (http / curl / differential) to model.Finding as json:"repro,omitempty". scan.go populates it from report.BuildRepro while the in-memory Variant is live, so the JSON reporter now includes copy-paste reproductions inline on every finding — no separate markdown or HTML render pass required. Also mark shipped v1.1 items in ROADMAP.md and POST_V01.md: jwt-kid- injection, jwt-alg-confusion, jwt-jwks-spoof, jwt-hmac-crack, markdown reporter, and idor-cross-tenant are all already live. Co-Authored-By: Claude Sonnet 4.6 <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.
Summary
model.FindingReprostruct (http,curl,differentialstring fields) tomodel.Findingasjson:"repro,omitempty"scan.goviareport.BuildReprowhile the in-memoryVariantis still live (before it is dropped from serialization)--repro-credscontrols credential redaction as with markdown/htmldocs/ROADMAP.mdandPOST_V01.mdto mark six already-shipped v1.1 items:jwt-kid-injection,jwt-alg-confusion,jwt-jwks-spoof,jwt-hmac-crack, markdown reporter, andidor-cross-tenantTest plan
go test ./...passes (all 13 packages)TestJSON_FindingWithRepro_ContainsReproBlock— JSON output includes"repro"with"http","curl","differential"keys whenFinding.Reprois setTestJSON_FindingWithoutRepro_NoReproKey—"repro"key absent whenFinding.Reprois nil (omitempty)TestJSON_ReproStable_ByteIdentical— repro-containing output is byte-identical across two renders (D26)TestJSON_Repro_ValidJSON— parsed JSON has expected repro shape; second finding has nil repro🤖 Generated with Claude Code