Repository navigation
feat(report): add Markdown export with metadata, disclaimer and escaping (#16) - #26
Merged
Merged
Conversation
3 tasks
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.
For #16:
[S8] Markdown export with metadata, disclaimer and escaping of vendor stringsWhat and why
The platform made the commits and the branch from the files the agent handed back; it does not use the agent's own git state on the box, so anything the summary says about committing, branching or pushing describes only what the agent could do there.
The agent's summary, quoted:
The agent's decisions, and where it departed from the issue or the design, quoted:
Changes
internal/report/markdown.go— 358 linesinternal/report/markdown_test.go— 342 linesinternal/report/testdata/complete.golden.md— 87 linesinternal/report/testdata/partial.golden.md— 47 linesinternal/report/testdata/failed.golden.md— 34 linesinternal/report/testdata/unreachable.golden.md— 27 linesinternal/report/testdata/injection.golden.md— 52 linescmd/touchstone/main.go— 80 linescmd/touchstone/main_test.go— 176 linesinternal/service/scan.go— 100 linestestdata/report.golden.md— 39 linestestdata/report.golden.json— 47 linesREADME.md— 39 lines13 file(s) in all.
Acceptance, from the issue
`touchstone scan --format md` renders the report via golden-file tests— the agent says:--format md renders via report.WriteMarkdown; golden tests in internal/report (5 fixtures) and cmd/touchstone (testdata/report.golden.md) pass.Timestamp, tool version, vuln-data date and the fixed Low-confidence disclaimer are always present; `lookup_status` not COMPLETE renders "lookup incomplete", n…— the agent says:Header always prints Started/Completed, Tool version, Vuln data as of ('unknown' when absent) and the disclaimer; non-COMPLETE renders 'lookup incomplete', tes…A fixture with Markdown/HTML injection in a component name and evidence string renders escaped— the agent says:injection fixture puts script/img/iframe, links, emphasis, table pipes and newlines in name, evidence and every vendor field; golden plus TestInjectionIsEscape…The items are the issue's own; each status is the agent's report, which the platform has not checked.
Checks
Review this like any other change. The agent ran on the member's own machine from the text of the issue; the platform has not built or tested it. CI results appear on this pull request.
passedHow this pull request was made
Opened by the platform from a coding agent's run on a member's box (run
5c8dd9c0). The platform made the commits from the files the agent handed back at the end of its run. Nothing is merged automatically.