Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Aqua: Update parser deduplication criteria 🐛 #10595

Merged
merged 1 commit into from
Jul 22, 2024

Conversation

manuel-sommer
Copy link
Contributor

@manuel-sommer manuel-sommer commented Jul 19, 2024

Updates the parser deduplication criteria to ensure that all findings of a given CPE are recorded within dojo

closes #10586

Copy link

DryRun Security Summary

The code changes in this pull request appear to be a reasonable improvement to the Aqua security scan parser in the dojo/tools/aqua/parser.py file, which helps to ensure that findings are uniquely identified based on the combination of the CPE (Common Platform Enumeration), the vulnerability name, and the resource path, and also includes a function to parse the output of an Aqua security scan and convert it into a list of Finding objects for the Django Vulnerability Engagement Tracker (DefectDojo) application.

Expand for full summary

Summary:

The code changes in this pull request appear to be a reasonable improvement to the Aqua security scan parser in the dojo/tools/aqua/parser.py file. The key change is the addition of the resource.get("path", "None") to the unique_key variable, which is used to identify unique findings. This change helps to ensure that findings are uniquely identified based on the combination of the CPE (Common Platform Enumeration), the vulnerability name, and the resource path. This is an important improvement, as it can help to prevent duplicate findings from being reported, which can improve the accuracy and usefulness of the security scan results.

Additionally, the get_items function in the file is responsible for parsing the output of an Aqua security scan and converting it into a list of Finding objects, which can be used by the Django Vulnerability Engagement Tracker (DefectDojo) application. This is a common task for an application security engineer, as they often need to integrate various security tools and services into their organization's security workflows. Overall, the code changes seem to be a reasonable improvement to the Aqua security scan parser, and there don't appear to be any obvious security concerns in the provided code.

Files Changed:

  • dojo/tools/aqua/parser.py: The key change in this file is the addition of the resource.get("path", "None") to the unique_key variable, which is used to identify unique findings. This change helps to ensure that findings are uniquely identified based on the combination of the CPE (Common Platform Enumeration), the vulnerability name, and the resource path. The get_items function in this file is responsible for parsing the output of an Aqua security scan and converting it into a list of Finding objects, which can be used by the Django Vulnerability Engagement Tracker (DefectDojo) application.

Code Analysis

We ran 9 analyzers against 1 file and 0 analyzers had findings. 9 analyzers had no findings.

Riskiness

🟢 Risk threshold not exceeded.

View PR in the DryRun Dashboard.

@Maffooch Maffooch changed the title 🐛 fix aqua issue #10586 Aqua: Update parser deduplication criteria Jul 22, 2024
@Maffooch Maffooch changed the title Aqua: Update parser deduplication criteria Aqua: Update parser deduplication criteria 🐛 Jul 22, 2024
Copy link
Contributor

@mtesauro mtesauro left a comment

Choose a reason for hiding this comment

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

Approved

@mtesauro mtesauro merged commit f636221 into DefectDojo:bugfix Jul 22, 2024
124 checks passed
@manuel-sommer manuel-sommer deleted the aqua_10586 branch July 22, 2024 15:01
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants