Skip to content

Adding parser for Veracode SCA (SourceClear) JSON/CSV files #6698

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

Merged
merged 1 commit into from
Aug 19, 2022

Conversation

coheigea
Copy link
Contributor

This is a new parser for Veracode SCA (SourceClear). It supports both CSV files that can be exported from the UI, as well as the JSON exports available via the API.

@github-actions github-actions bot added docs parser settings_changes Needs changes to settings.py based on changes in settings.dist.py included in this PR unittests labels Aug 12, 2022
@coheigea coheigea force-pushed the coheigea/veracode_sca branch 3 times, most recently from d43e855 to 781772d Compare August 12, 2022 14:40
Copy link
Contributor

@damiencarol damiencarol left a comment

Choose a reason for hiding this comment

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

It's a very interesting PR.
But few things bother me:

  1. it seems the CSV and JSON have the same data but not in the same format. but the parsers set values differently. for ex in JSON we set unique_id but in CSV we set vuln_id.
  2. it seems that the report have Issue and Vuln data but the parser filter to only have Issue when the type is Vuln. so should we just consider data of vuln? this way de-duplication will be easier. (we can use the id of the vulnerability directly for de-duplication)

@coheigea coheigea force-pushed the coheigea/veracode_sca branch 2 times, most recently from f6523a8 to e7628b6 Compare August 17, 2022 09:18
@coheigea
Copy link
Contributor Author

@damiencarol Thanks for the feedback, I've made all the changes suggested, apart from your second point. The vulnerability data alone isn't enough to parse, for example the library information isn't in the vulnerability section.

@coheigea coheigea requested a review from damiencarol August 17, 2022 09:24
@coheigea coheigea force-pushed the coheigea/veracode_sca branch from e7628b6 to 992b92b Compare August 18, 2022 12:15
@damiencarol
Copy link
Contributor

@damiencarol Thanks for the feedback, I've made all the changes suggested, apart from your second point. The vulnerability data alone isn't enough to parse, for example the library information isn't in the vulnerability section.

My comment was more to align data on both parser (for ex use the vuln id in both parser for unique_id_from_tools attribute) you can still use data from the issue for things like components. But the PR is good enough IMO. let release this one. more PR will come if modifications are needed

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 946b930 into DefectDojo:dev Aug 19, 2022
@coheigea coheigea deleted the coheigea/veracode_sca branch August 19, 2022 14:32
shipko pushed a commit to shipko/django-DefectDojo that referenced this pull request Sep 5, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
docs parser settings_changes Needs changes to settings.py based on changes in settings.dist.py included in this PR unittests
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants