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

Improved json report #403

Merged
merged 4 commits into from
Jul 30, 2024
Merged

Improved json report #403

merged 4 commits into from
Jul 30, 2024

Conversation

lauraschauer
Copy link
Contributor

@lauraschauer lauraschauer commented Jul 29, 2024

Changes in this pull request:

  1. Added a new feature to exclude the diff information from the JSON report. Users can now choose to remove the diff field from the JSON reports in two ways:
    • Using the CLI option --no-diff when running the CLI version of Prospector. Example of execution with the --no-diff option:
      ./run_prospector.sh CVE-2020-1925 --repository https://github.com/apache/olingo-odata4 --no-diff

    • Setting the no_diff parameter to True in the config.yaml file. By default the value is set to False.

...
report:
 format: json
 name: prospector-report
 no_diff: False
...

This improvement aims to generate lighter JSON reports. Previously, for each commit, the entire diff was saved in the report, resulting in long and heavy files. By providing the option to exclude the diff, we make the reports more concise and easier to manage.

  1. The JSON report now includes a new field called parameters. This field contains the exact values passed to the prospector function during execution. With this addition, users can now easily track and understand the specific parameters used to generate the results by opening the report file. An example of the JSON report with the parameters tracking is the following:
"parameters": {
       "vulnerability_id": "CVE-2020-1925",
       "repository_url": "https://github.com/apache/olingo-odata4",
       "publication_date": "",
       "vuln_descr": null,
       "version_interval": "None:None",
       "modified_files": [],
       "advisory_keywords": [],
       "use_nvd": true,
       "backend_address": "http://backend:8000",
       "use_backend": "always",
       "git_cache": "/tmp/gitcache",
       "limit_candidates": 2000
   },

@lauraschauer lauraschauer force-pushed the improved-json-report branch from de4e87c to af2a9f2 Compare July 29, 2024 08:06
@lauraschauer lauraschauer force-pushed the improved-json-report branch from adb73e5 to aa77cf6 Compare July 30, 2024 08:35
@copernico copernico merged commit f8c85d2 into SAP:main Jul 30, 2024
3 checks passed
@lauraschauer lauraschauer deleted the improved-json-report branch August 9, 2024 12:22
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants