-
Notifications
You must be signed in to change notification settings - Fork 593
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
Similar Packages Should Be Aggregated #1162
Comments
Wow great find thanks so much @cpendery! |
Changing Can I ask more about the use cases that motivated package merging? Maybe we can find a good workaround for your needs (for instance |
@wagoodman , thanks for the update and additional comments. Following up from the initial issue from @cpendery; the use case here is to eliminate what appear to be duplicate vulnerabilities (or at least very similar vulnerabilites) being reported after running grype on the sbom generated by syft. The pURL, vulnerability id and datasource are all the same and the only difference is the virtual path. With the original example (using syft 0.59.0 and grype 0.51.0) Looking at the syft output (and choosing an example package) we can see the same pURL Then we can run grype Using some very rough jq we can try to count some of the vulnerabilities that appear to be duplicates (except for the virtual path). Using the example pURL As you mentioned it is possible to filter out some of the apparent duplicates pre/post running syft or grype but it would be very nice to be able to get the vulnerability, package (and then multiple virtual paths where the package is used) as part of the output without doing additional processing/merging for this case where the pURL (and almost everything else) is the same and the only difference is the virtual path. Will try to follow up on this in the next community meeting. |
What happened:
Producing an sbom with Syft is creating almost duplicate packages, where they are derived from different sources, but all of the information about the dependency is the same. We see this primarily using the
java-cataloger
Ex:
What you expected to happen:
I'd expect these two packages in the sbom to be aggregated into a single object where all the possible sources are included as an array, rather than having multiple of the same package where this is the only difference.
How to reproduce it (as minimally and precisely as possible):
This shows that the same purl is appearing multiple times, but looking at the full sbom output shows the separate items that are all the same except for some metadata attributes which could be combined
Anything else we need to know?:
Environment:
syft version
: v0.53.2cat /etc/os-release
or similar): MacOSThe text was updated successfully, but these errors were encountered: