Skip to content

Commit

Permalink
t
Browse files Browse the repository at this point in the history
  • Loading branch information
pna-nca committed May 3, 2024
1 parent 2ed1a59 commit 907f638
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions dojo/tools/neuvector/parser.py
Original file line number Diff line number Diff line change
Expand Up @@ -57,8 +57,7 @@ def get_items(self, tree, test):
items[unique_key] = item

# asset-style collection with compliance issues of several assets
#if "compliance_issues" in tree:
#
# if "compliance_issues" in tree:
return list(items.values())


Expand Down Expand Up @@ -126,6 +125,7 @@ def get_item(vulnerability, test):

return finding


def get_asset_item(vulnerability, test):
severity = (
convert_severity(vulnerability.get("severity"))
Expand All @@ -142,7 +142,7 @@ def get_asset_item(vulnerability, test):
mitigation += "update the affected packages to the following:\n"
description += "\nThe following packages are affected:\n"

for package_name, package_version in packages.iteritems():
for package_name, package_version in packages.items():
mitigation += "{name}: {version}".format(name=package_name, version=package_version)
description += "{name}: {version}".format(name=package_name, version=package_version)

Expand Down Expand Up @@ -184,6 +184,7 @@ def get_asset_item(vulnerability, test):

return finding


# see neuvector/share/types.go
def convert_severity(severity):
if severity.lower() == "critical":
Expand Down

0 comments on commit 907f638

Please sign in to comment.