grype/cmd/grype
Feroz Salam a3ade4242b
fix: take VEX docs into account when --fail-on is set (#1657)
* Take VEX docs into account when --fail-on is set

Previously, VEX documents provided to Grype when --fail-on was set were not
taken into account. That led to inconsistent behaviour where a vulnerability
would be ignored when only `--vex` was specified, but would be included in
Grype output when both `--vex` and `--fail-on` were specified.

This change fixes that by moving the failure severity check to after the VEX
documents provided are tested.

I have also added a unit test to check that the combination of VEX docs and
failure severity checks works as expected.

Signed-off-by: Feroz Salam <feroz.salam@isovalent.com>

* Fix typos

Signed-off-by: Feroz Salam <feroz.salam@isovalent.com>

---------

Signed-off-by: Feroz Salam <feroz.salam@isovalent.com>
2024-01-23 10:08:25 -05:00
..
cli fix: take VEX docs into account when --fail-on is set (#1657) 2024-01-23 10:08:25 -05:00
internal upgrade syft with latest SBOM creation API (#1662) 2024-01-17 12:33:09 -05:00
main.go fix: terminal clobbering when commands return errors (#1505) 2023-09-20 12:17:33 -04:00