File tree Expand file tree Collapse file tree 1 file changed +3
-3
lines changed
Expand file tree Collapse file tree 1 file changed +3
-3
lines changed Original file line number Diff line number Diff line change @@ -172,15 +172,15 @@ jobs:
172172 echo "<details>" >> $GITHUB_STEP_SUMMARY
173173 echo "<summary>View $RESULTS finding(s)</summary>" >> $GITHUB_STEP_SUMMARY
174174 echo "" >> $GITHUB_STEP_SUMMARY
175- echo "| Level | Security | Rule | Location | Message |" >> $GITHUB_STEP_SUMMARY
176- echo "|-------|---------- |------|----------|---------|" >> $GITHUB_STEP_SUMMARY
175+ echo "| Level | Sec-Sev | Rule | Location | Message |" >> $GITHUB_STEP_SUMMARY
176+ echo "|-------|---------|------|----------|---------|" >> $GITHUB_STEP_SUMMARY
177177 # Join results with rules to get security-severity (which is on rule definitions, not results)
178178 jq -r '
179179 (.runs[0].tool.driver.rules // []) as $driver_rules |
180180 ([.runs[0].tool.extensions[]?.rules // []] | add // []) as $ext_rules |
181181 ($driver_rules + $ext_rules | map({(.id): (.properties["security-severity"] // null)}) | add // {}) as $severities |
182182 .runs[0].results[] |
183- "| \(.level // "warning") | \($severities[.ruleId] // "N/A") | \(.ruleId // "unknown") | `\(.locations[0].physicalLocation.artifactLocation.uri // "unknown"):\(.locations[0].physicalLocation.region.startLine // "?")` | \(.message.text | gsub("\n"; " ") | gsub("\\|"; "\\\\|") | .[0:80 ]) |"
183+ "| \(.level // "warning") | \($severities[.ruleId] // "N/A") | \(.ruleId // "unknown") | `\(.locations[0].physicalLocation.artifactLocation.uri // "unknown"):\(.locations[0].physicalLocation.region.startLine // "?")` | \(.message.text | gsub("\n"; " ") | gsub("\\|"; "\\\\|") | .[0:120 ]) |"
184184 ' "$sarif" >> $GITHUB_STEP_SUMMARY
185185 echo "" >> $GITHUB_STEP_SUMMARY
186186 echo "</details>" >> $GITHUB_STEP_SUMMARY
You can’t perform that action at this time.
0 commit comments