Skip to content

Commit 3ba1156

Browse files
committed
feature: Upload sourceId when available from SARIF CF-1813
Note that this will upload it for all the tools and affect the UUID generation, thus marking current issues as fixed/new To have this feature only for some tools this is not enough
1 parent 642d8bf commit 3ba1156

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

cmd/upload.go

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -103,6 +103,7 @@ func processSarif(sarif Sarif) [][]map[string]interface{} {
103103
"message": result.Message.Text,
104104
"level": pattern.Level,
105105
"category": pattern.Category,
106+
"sourceId": result.RuleID,
106107
})
107108
}
108109
}
@@ -133,6 +134,7 @@ func processSarif(sarif Sarif) [][]map[string]interface{} {
133134
"line": obj["line"].(int),
134135
},
135136
},
137+
"sourceId": obj["sourceId"].(string),
136138
}
137139

138140
// Check if we already have an entry for this filename

0 commit comments

Comments
 (0)