Skip to content

Conversation

afdesk
Copy link
Contributor

@afdesk afdesk commented Oct 29, 2024

Description

This PR updates dependencies related on Trivy 0.57.0 and fixes some vulnerabilities inside these ones.

Notes:

Before:

trivy rootfs .
2024-10-29T17:43:58+06:00	INFO	[vuln] Vulnerability scanning is enabled
2024-10-29T17:43:58+06:00	INFO	[secret] Secret scanning is enabled
2024-10-29T17:43:58+06:00	INFO	[secret] If your scanning is slow, please try '--scanners vuln' to disable secret scanning
2024-10-29T17:43:58+06:00	INFO	[secret] Please see also https://aquasecurity.github.io/trivy/v0.56/docs/scanner/secret#recommendation for faster secret detection
2024-10-29T17:43:58+06:00	INFO	Number of language-specific files	num=1
2024-10-29T17:43:58+06:00	INFO	[gobinary] Detecting vulnerabilities...

to (gobinary)

Total: 3 (UNKNOWN: 0, LOW: 1, MEDIUM: 1, HIGH: 0, CRITICAL: 1)

┌──────────────────────────────────┬─────────────────────┬──────────┬────────┬──────────────────────┬─────────────────────────────────┬───────────────────────────────────────────────────────────┐
│             Library              │    Vulnerability    │ Severity │ Status │  Installed Version   │          Fixed Version          │                           Title                           │
├──────────────────────────────────┼─────────────────────┼──────────┼────────┼──────────────────────┼─────────────────────────────────┼───────────────────────────────────────────────────────────┤
│ github.com/docker/docker         │ CVE-2024-41110      │ CRITICAL │ fixed  │ v26.1.3+incompatible │ 23.0.15, 26.1.5, 27.1.1, 25.0.6 │ moby: Authz zero length regression                        │
│                                  │                     │          │        │                      │                                 │ https://avd.aquasec.com/nvd/cve-2024-41110                │
├──────────────────────────────────┼─────────────────────┼──────────┤        ├──────────────────────┼─────────────────────────────────┼───────────────────────────────────────────────────────────┤
│ github.com/open-policy-agent/opa │ CVE-2024-8260       │ MEDIUM   │        │ v0.65.0              │ 0.68.0                          │ opa: OPA SMB Force-Authentication                         │
│                                  │                     │          │        │                      │                                 │ https://avd.aquasec.com/nvd/cve-2024-8260                 │
├──────────────────────────────────┼─────────────────────┼──────────┤        ├──────────────────────┼─────────────────────────────────┼───────────────────────────────────────────────────────────┤
│ google.golang.org/grpc           │ GHSA-xr7q-jx4m-x55m │ LOW      │        │ v1.64.0              │ 1.64.1                          │ Private tokens could appear in logs if context containing │
│                                  │                     │          │        │                      │                                 │ gRPC metadata is...                                       │
│                                  │                     │          │        │                      │                                 │ https://github.com/advisories/GHSA-xr7q-jx4m-x55m         │
└──────────────────────────────────┴─────────────────────┴──────────┴────────┴──────────────────────┴─────────────────────────────────┴───────────────────────────────────────────────────────────┘

After

 trivy rootfs .                                           
2024-10-29T17:40:31+06:00	INFO	[vuln] Vulnerability scanning is enabled
2024-10-29T17:40:31+06:00	INFO	[secret] Secret scanning is enabled
2024-10-29T17:40:31+06:00	INFO	[secret] If your scanning is slow, please try '--scanners vuln' to disable secret scanning
2024-10-29T17:40:31+06:00	INFO	[secret] Please see also https://aquasecurity.github.io/trivy/v0.56/docs/scanner/secret#recommendation for faster secret detection
2024-10-29T17:40:31+06:00	INFO	Number of language-specific files	num=1
2024-10-29T17:40:31+06:00	INFO	[gobinary] Detecting vulnerabilities...

Checklist

  • I've read the guidelines for contributing to this repository.
  • I've added tests that prove my fix is effective or that my feature works.
  • I've updated the documentation with the relevant information (if needed).
  • I've added usage information (if the PR introduces new options)
  • I've included a "before" and "after" example to the description (if the PR is a user interface change).

@github-actions github-actions bot added the misc label Oct 29, 2024
@afdesk afdesk changed the title chore: bump up trivy to v0.56.2 chore: bump up trivy to v0.57.0 Nov 5, 2024
@afdesk afdesk force-pushed the chore/bump-trivy-0.56.2 branch from d7b3e21 to 709ae3c Compare November 13, 2024 14:00
@afdesk afdesk force-pushed the chore/bump-trivy-0.56.2 branch from 033fb43 to 5fa71c0 Compare November 15, 2024 05:12
@afdesk afdesk marked this pull request as ready for review November 15, 2024 05:51
@afdesk
Copy link
Contributor Author

afdesk commented Nov 15, 2024

@simar7 @nikpivkin there were some changes (renaming) in iac/rego methods.
Could you check please that I update them correctly here? thanks!

@iamhalje
Copy link

iamhalje commented Nov 18, 2024

PR mentions an upgrade to v0.57.0, but v0.57.1 is already available

Copy link
Member

@simar7 simar7 left a comment

Choose a reason for hiding this comment

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

I reviewed the pkg/ changes and they lgtm. @nikpivkin could you also take another look?

@afdesk afdesk changed the title chore: bump up trivy to v0.57.0 chore: bump up trivy to v0.57.1 Nov 19, 2024
@afdesk
Copy link
Contributor Author

afdesk commented Nov 19, 2024

PR mentions an upgrade to v0.57.0, but v0.57.1 is already available

fixed

@simar7 simar7 mentioned this pull request Nov 19, 2024
5 tasks
@@ -690,7 +690,7 @@ policiesBundle:
# -- repository of the policies bundle
repository: aquasecurity/trivy-checks
Copy link
Contributor

Choose a reason for hiding this comment

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

I think it's worth changing the default value in the future after the release of trivy-checks in DockerHub in case the use of embedded checks is disabled.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

yes, sure.

Copy link
Contributor

@nikpivkin nikpivkin left a comment

Choose a reason for hiding this comment

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

LGTM!

@afdesk afdesk merged commit 6f3499c into aquasecurity:main Nov 19, 2024
10 checks passed
@afdesk afdesk deleted the chore/bump-trivy-0.56.2 branch November 19, 2024 05:13
@hebestreit
Copy link

Did you miss to bump the version of the chart or is there any reason?

https://github.com/aquasecurity/trivy-operator/blob/main/deploy/helm/Chart.yaml#L9

I'm happy to provide a PR for the change.

@hebestreit
Copy link

I've just seen that other changes have also been merged recently, and I assume it's not being updated because of the upcoming release?

I apologize for my impatience and the inconvenience.

@afdesk
Copy link
Contributor Author

afdesk commented Nov 20, 2024

I've just seen that other changes have also been merged recently, and I assume it's not being updated because of the upcoming release?

I apologize for my impatience and the inconvenience.

It's OK
You're right, we want to cut a new release today/tomorrow, but we need to clarify some details.
sorry for inconvenience

afdesk added a commit to maltemorgenstern/trivy-operator that referenced this pull request Jun 2, 2025
* chore: bump up trivy to v0.56.2

* bump up trivy-check

* fix dep conflicts

* refactor: rebase go.mod

* chore: update static yaml files

* chore: rerun tests

* fix: incorrect check for duplicate controller names

* ci: bump timeouts up 10 minutes

* chore: bump Trivy up 0.57.0

* chore: install yamllint

* chore: set up a specific ubuntu version for GH runners

* ci: bump up helm chart testing

* ci: set up a specific version for helm chart testing

* chore: increase a timeout for helm test

* ci: bump up timeouts

* chore: bump Trivy up in helm chart

* docs: bump up Trivy version

* chore: update static yaml

* chore: using docker.io as a registry

* chore: update docs and static yaml

* chore: skip validation of controller name

* chore: revert registry from docker to ghcr

* chore: remove timeouts for tests

* chore: bump up trivy-check tag

* chore: using embedded rego policies

* chore: show logs for failures

* chore: using mirror.gcr.io instead of ghcr.io

* update to trivy v0.57.1

---------

Co-authored-by: Simar <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants