From 62b9b509a0099f3d5ce1480837e5372bbd799705 Mon Sep 17 00:00:00 2001 From: Yong Yan Date: Wed, 23 Jun 2021 16:19:00 -0700 Subject: [PATCH] Fix Sarif output relationship target id format. --- flawfinder.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/flawfinder.py b/flawfinder.py index 22dd509..ff797f1 100755 --- a/flawfinder.py +++ b/flawfinder.py @@ -250,7 +250,7 @@ class SarifLogger(object): if cwestr: relationship = { "target": { - "id": int(cwestr.replace("CWE-", "").replace("!", "")), + "id": cwestr.replace("!", ""), "toolComponent": { "name": self.CWE_TAXONOMY_NAME, "guid": self.CWE_TAXONOMY_GUID,