Skip to content

feat: simplify default operation of cve-bin-tool #3437

@terriko

Description

@terriko

I'm currently working on updating our README.md and MANUAL.md file in preparation for the 3.3 release, and right now we list a few types of operation that could maybe be combined into one:

  • cve-bin-tool <directory/file> -- this tries to auto-detect components, including using the binary checkers and language component list parsers.
  • cve-bin-tool --input-file <file> -- this treats a single file (in .json or .csv format) as a bill of materials list
  • cve-bin-tool --sbom <sbom_filetype> --sbom-file <filename> -- scans an SBOM

What I think I'd like is for

cve-bin-tool <directory/file>

to work basically as expected no matter whether it's run as

cve-bin-tool my-directory/

or

cve-bin-tool my-component-list.csv

or

cve-bin-tool my-sbom.json

The first two already do work, but they throw an error encouraging people to use --input-file. I'm thinking we should leave the info message saying "this looks like a component list so I'm scanning it as such." but maybe plan to deprecate --input-file in a future release depending on how much of a pain that is.

I'm guessing SBOM auto-detection is more of a pain, since sbom quality is all over the map, but it should be doable at least for ones that have appropriate info in them. @anthonyharrison do you have any thoughts there?

And anyone else -- thoughts on streamlining? I'm basically just reading the docs and thinking "wow, this is way more complicated for the user than it needs to be.

Metadata

Metadata

Assignees

Labels

discussionDiscussion thread or meeting minutes that may not have any trivially fixable code issues associatedhacktoberfestgood issue for hacktoberfest participation

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions