Skip to content

feat: delimit between images in validate output#468

Merged
willmurphyscode merged 1 commit intomainfrom
feat-delimi-results-in-validate
Feb 12, 2025
Merged

feat: delimit between images in validate output#468
willmurphyscode merged 1 commit intomainfrom
feat-delimi-results-in-validate

Conversation

@willmurphyscode
Copy link
Copy Markdown
Contributor

Otherwise, it's easy for an operator to investigate the wrong image when investigating a quality gate failure.

Example of new output:


   Results used for image docker.io/anchore/test_images@sha256:c8d664b0e728d52f57eeb98ed1899c16d3b265f02ddfb41303d7a16c31e0b0f1:
    ├── 86723334-feee-4a64-8d9f-5878bfb3ee34 : grype[candidate]@path:../../+import-db=db.tar.gz (candidate)  against docker.io/anchore/test_images@sha256:c8d66
4b0e728d52f57eeb98ed1899c16d3b265f02ddfb41303d7a16c31e0b0f1
    └── 4b769e08-5b30-413f-a2b0-5226e03f3dd1 : grype[reference]@v0.86.1 (reference)  against docker.io/anchore/test_images@sha256:c8d664b0e728d52f57eeb98ed1899
c16d3b265f02ddfb41303d7a16c31e0b0f1
Deltas for docker.io/anchore/test_images@sha256:c8d664b0e728d52f57eeb98ed1899c16d3b265f02ddfb41303d7a16c31e0b0f1:
Match differences between tooling (with labels):
   TOOL PARTITION                                         PACKAGE                                             VULNERABILITY   LABEL      COMMENTARY
   grype[candidate]@path:../../+import-db=db.tar.gz ONLY  jcl-over-slf4j@0:1.7.25-4.module+el8+5161+5cac467c  CVE-2018-14040  (unknown)
   grype[candidate]@path:../../+import-db=db.tar.gz ONLY  jcl-over-slf4j@0:1.7.25-4.module+el8+5161+5cac467c  CVE-2019-16943  (unknown)
   grype[candidate]@path:../../+import-db=db.tar.gz ONLY  jcl-over-slf4j@0:1.7.25-4.module+el8+5161+5cac467c  CVE-2020-1695   (unknown)
   grype[candidate]@path:../../+import-db=db.tar.gz ONLY  jcl-over-slf4j@0:1.7.25-4.module+el8+5161+5cac467c  CVE-2020-36518  (unknown)
   grype[candidate]@path:../../+import-db=db.tar.gz ONLY  slf4j@0:1.7.25-4.module+el8+5161+5cac467c           CVE-2018-14040  (unknown)
   grype[candidate]@path:../../+import-db=db.tar.gz ONLY  slf4j@0:1.7.25-4.module+el8+5161+5cac467c           CVE-2019-16943  (unknown)
   grype[candidate]@path:../../+import-db=db.tar.gz ONLY  slf4j@0:1.7.25-4.module+el8+5161+5cac467c           CVE-2020-1695   (unknown)
   grype[candidate]@path:../../+import-db=db.tar.gz ONLY  slf4j@0:1.7.25-4.module+el8+5161+5cac467c           CVE-2020-36518  (unknown)

--------------------------------------------------------------------------------
   Results used for image docker.io/anchore/test_images@sha256:524ff8a75f21fd886ec7ed82387766df386671e8b77e898d05786118d5b7880b:
    ├── c14cbb69-43e2-479b-a509-1273ec83b38c : grype[candidate]@path:../../+import-db=db.tar.gz (candidate)  against docker.io/anchore/test_images@sha256:524ff
8a75f21fd886ec7ed82387766df386671e8b77e898d05786118d5b7880b
    └── 1a02b242-db41-48dc-9c18-82f02054f1af : grype[reference]@v0.86.1 (reference)  against docker.io/anchore/test_images@sha256:524ff8a75f21fd886ec7ed8238776
6df386671e8b77e898d05786118d5b7880b
Deltas for docker.io/anchore/test_images@sha256:524ff8a75f21fd886ec7ed82387766df386671e8b77e898d05786118d5b7880b:
Match differences between tooling (with labels):
   TOOL PARTITION                 PACKAGE                                             VULNERABILITY   LABEL          COMMENTARY
   grype[reference]@v0.86.1 ONLY  php-cli@7.4.30-1.module_el8.7.0+1190+d11b935a       CVE-2021-21707  FalsePositive  (got rid of a former FP 🙌)
   grype[reference]@v0.86.1 ONLY  php-cli@7.4.30-1.module_el8.7.0+1190+d11b935a       CVE-2021-21708  FalsePositive  (got rid of a former FP 🙌)
   grype[reference]@v0.86.1 ONLY  php-cli@7.4.30-1.module_el8.7.0+1190+d11b935a       CVE-2021-32610  TruePositive   (this is a new FN 😱)
   grype[reference]@v0.86.1 ONLY  php-common@7.4.30-1.module_el8.7.0+1190+d11b935a    CVE-2021-21707  FalsePositive  (got rid of a former FP 🙌)
   grype[reference]@v0.86.1 ONLY  php-common@7.4.30-1.module_el8.7.0+1190+d11b935a    CVE-2021-21708  FalsePositive  (got rid of a former FP 🙌)
   grype[reference]@v0.86.1 ONLY  php-common@7.4.30-1.module_el8.7.0+1190+d11b935a    CVE-2021-32610  TruePositive   (this is a new FN 😱)
   grype[reference]@v0.86.1 ONLY  php-fpm@7.4.30-1.module_el8.7.0+1190+d11b935a       CVE-2021-21707  FalsePositive  (got rid of a former FP 🙌)
   grype[reference]@v0.86.1 ONLY  php-fpm@7.4.30-1.module_el8.7.0+1190+d11b935a       CVE-2021-21708  FalsePositive  (got rid of a former FP 🙌)
   grype[reference]@v0.86.1 ONLY  php-fpm@7.4.30-1.module_el8.7.0+1190+d11b935a       CVE-2021-32610  TruePositive   (this is a new FN 😱)
   grype[reference]@v0.86.1 ONLY  php-json@7.4.30-1.module_el8.7.0+1190+d11b935a      CVE-2021-21707  FalsePositive  (got rid of a former FP 🙌)
   grype[reference]@v0.86.1 ONLY  php-json@7.4.30-1.module_el8.7.0+1190+d11b935a      CVE-2021-21708  FalsePositive  (got rid of a former FP 🙌)
   grype[reference]@v0.86.1 ONLY  php-json@7.4.30-1.module_el8.7.0+1190+d11b935a      CVE-2021-32610  TruePositive   (this is a new FN 😱)
   grype[reference]@v0.86.1 ONLY  php-mbstring@7.4.30-1.module_el8.7.0+1190+d11b935a  CVE-2021-21707  FalsePositive  (got rid of a former FP 🙌)
   grype[reference]@v0.86.1 ONLY  php-mbstring@7.4.30-1.module_el8.7.0+1190+d11b935a  CVE-2021-21708  FalsePositive  (got rid of a former FP 🙌)
   grype[reference]@v0.86.1 ONLY  php-mbstring@7.4.30-1.module_el8.7.0+1190+d11b935a  CVE-2021-32610  TruePositive   (this is a new FN 😱)
   grype[reference]@v0.86.1 ONLY  php-opcache@7.4.30-1.module_el8.7.0+1190+d11b935a   CVE-2021-21707  FalsePositive  (got rid of a former FP 🙌)
   grype[reference]@v0.86.1 ONLY  php-opcache@7.4.30-1.module_el8.7.0+1190+d11b935a   CVE-2021-21708  FalsePositive  (got rid of a former FP 🙌)
   grype[reference]@v0.86.1 ONLY  php-opcache@7.4.30-1.module_el8.7.0+1190+d11b935a   CVE-2021-32610  TruePositive   (this is a new FN 😱)
   grype[reference]@v0.86.1 ONLY  php-pdo@7.4.30-1.module_el8.7.0+1190+d11b935a       CVE-2021-21707  FalsePositive  (got rid of a former FP 🙌)
   grype[reference]@v0.86.1 ONLY  php-pdo@7.4.30-1.module_el8.7.0+1190+d11b935a       CVE-2021-21708  FalsePositive  (got rid of a former FP 🙌)
   grype[reference]@v0.86.1 ONLY  php-pdo@7.4.30-1.module_el8.7.0+1190+d11b935a       CVE-2021-32610  TruePositive   (this is a new FN 😱)
   grype[reference]@v0.86.1 ONLY  php-xml@7.4.30-1.module_el8.7.0+1190+d11b935a       CVE-2021-21707  FalsePositive  (got rid of a former FP 🙌)
   grype[reference]@v0.86.1 ONLY  php-xml@7.4.30-1.module_el8.7.0+1190+d11b935a       CVE-2021-21708  FalsePositive  (got rid of a former FP 🙌)
   grype[reference]@v0.86.1 ONLY  php-xml@7.4.30-1.module_el8.7.0+1190+d11b935a       CVE-2021-32610  TruePositive   (this is a new FN 😱)
   grype[reference]@v0.86.1 ONLY  php@7.4.30-1.module_el8.7.0+1190+d11b935a           CVE-2021-21707  FalsePositive  (got rid of a former FP 🙌)
   grype[reference]@v0.86.1 ONLY  php@7.4.30-1.module_el8.7.0+1190+d11b935a           CVE-2021-21708  FalsePositive  (got rid of a former FP 🙌)
   grype[reference]@v0.86.1 ONLY  php@7.4.30-1.module_el8.7.0+1190+d11b935a           CVE-2021-32610  TruePositive   (this is a new FN 😱)

--------------------------------------------------------------------------------
   Results used for image docker.io/anchore/test_images@sha256:fc6f7a37d7e320f6ff3643d4ec9a208adb1462cd16027f045b56563e12bb0461:
    ├── fba9c2d8-dba1-46cb-ac6f-e9ff4264d93e : grype[candidate]@path:../../+import-db=db.tar.gz (candidate)  against docker.io/anchore/test_images@sha256:fc6f7
a37d7e320f6ff3643d4ec9a208adb1462cd16027f045b56563e12bb0461
    └── 864b4b43-5137-4192-a2ef-eb6a266b14c7 : grype[reference]@v0.86.1 (reference)  against docker.io/anchore/test_images@sha256:fc6f7a37d7e320f6ff3643d4ec9a2
08adb1462cd16027f045b56563e12bb0461
--------------------------------------------------------------------------------

Otherwise, it's easy for an operator to investigate the wrong image when
investigating a quality gate failure.

Signed-off-by: Will Murphy <willmurphyscode@users.noreply.github.com>
@willmurphyscode willmurphyscode self-assigned this Feb 12, 2025
Copy link
Copy Markdown
Contributor

@kzantow kzantow left a comment

Choose a reason for hiding this comment

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

👍 much more clear to me 🎉

@willmurphyscode willmurphyscode merged commit dfb8d10 into main Feb 12, 2025
@willmurphyscode willmurphyscode deleted the feat-delimi-results-in-validate branch February 12, 2025 15:48
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Archived in project

Development

Successfully merging this pull request may close these issues.

3 participants