anchore / grype

A vulnerability scanner for container images and filesystems
Apache License 2.0
8.7k stars 569 forks source link

Add more views into grype results #2199

Open wagoodman opened 1 week ago

wagoodman commented 1 week ago

Today there are a few ways to see the data that grype raises up. The default view is table which is a summarization of findings, json shows you all we know about every match, cyclonedx/cyclonedx-json, sarif, and template if you enjoy the golang template language. When users run grype and see the default results table it is reasonable to ask "what is actionable about this output"? Depending on the package type or location there are different answers here.

We introduced the explain command as an experiment last year to be a way to "dig" into a single row to get an opinionated view into the data (without having the full json data shown). We want to be able to elevate that command further, but it isn't immediately clear where.

We've also had several asks to add file location to the table output to help with report after actions ("what do I do now that I have CVE X against package Y??"). This hinders the summarization of that table, so we've resisted changing the default view here.

All of this hints that we need more ways to describe the same results from multiple perspectives. I think any default view will need to be static output to serve existing needs, but other output options could be interactive allowing the user to filter/find/select/dig dynamically.

Some ideas the team chatted about that are more on the "static" side: