Skip to content

Conversation

irgaly
Copy link
Contributor

@irgaly irgaly commented Jan 26, 2024


This PR supports SARIF file from Trivy.

Trivy SARIF sample
https://github.com/aquasecurity/trivy-sarif-demo/blob/d1968305c1133a0efd42bde85cd3bbefa68aa960/debug-trivy-results.sarif

SARIF v2.1.0 3.29.4 region property
https://docs.oasis-open.org/sarif/sarif/v2.1.0/csprd01/sarif-v2.1.0-csprd01.html#_Toc10541120

SARIF may not have a region property. This PR fixes reviewdog can parse SARIF with no region properties.

),
Code: code,
Suggestions: suggestionsMap[path],
OriginalOutput: string(original),
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

OriginalOutput is SARIF JSON now.

@irgaly irgaly self-assigned this Jan 26, 2024
Copy link
Contributor

@shogo82148 shogo82148 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@shogo82148 shogo82148 merged commit ea72341 into reviewdog:master Jan 30, 2024
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.

[BUG] Sarif format not working
2 participants