Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Bump github.com/go-jose/go-jose to v3.0.3 to fix CVE-2024-28180 #6854

Merged
merged 2 commits into from Mar 14, 2024

Conversation

wallrj
Copy link
Member

@wallrj wallrj commented Mar 14, 2024

This should fix the failing trivy tests in test grid which are reporting that cert-manager controller is vulnerable to https://avd.aquasec.com/nvd/2024/cve-2024-28180/:

Package jose aims to provide an implementation of the Javascript Object Signing and Encryption set of standards. An attacker could send a JWE containing compressed data that used large amounts of memory and CPU when decompressed by Decrypt or DecryptMulti. Those functions now return an error if the decompressed data would exceed 250kB or 10x the compressed size (whichever is larger). This vulnerability has been patched in versions 4.0.1, 3.0.3 and 2.6.3.

We think this is a false positive, because the cert-manager controller does not handle JWE.
and because govulncheck reports that the controller is not vulnerable to this issue:

$ make go-workspace
go work init
go work use . ./cmd/acmesolver ./cmd/cainjector ./cmd/controller ./cmd/startupapicheck ./cmd/webhook ./test/integration ./test/e2e

$ GOTOOLCHAIN=go1.22.1 govulncheck -show verbose ./...
Scanning your code and 1508 packages across 160 dependent modules for known vulnerabilities...

No vulnerabilities found.

Nevertheless, we are updating the module for the sake of silencing the trivy alerts in our repo and of any of our users.

I ran the following commands to update the go-jose module:

find . -name go.mod -execdir go get github.com/go-jose/go-jose/v3@v3.0.3 \; 
make tidy

/kind cleanup

Bump github.com/go-jose/go-jose to v3.0.3 to fix CVE-2024-28180

find . -name go.mod -execdir go get github.com/go-jose/go-jose/v3@v3.0.3 \;
make tidy

Signed-off-by: Richard Wall <richard.wall@venafi.com>
Signed-off-by: Richard Wall <richard.wall@venafi.com>
@jetstack-bot jetstack-bot added release-note Denotes a PR that will be considered when it comes time to generate release notes. kind/cleanup Categorizes issue or PR as related to cleaning up code, process, or technical debt. dco-signoff: yes Indicates that all commits in the pull request have the valid DCO sign-off message. size/M Denotes a PR that changes 30-99 lines, ignoring generated files. labels Mar 14, 2024
@inteon
Copy link
Member

inteon commented Mar 14, 2024

/approve
/lgtm

@jetstack-bot jetstack-bot added the lgtm Indicates that a PR is ready to be merged. label Mar 14, 2024
@jetstack-bot
Copy link
Collaborator

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: inteon

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@jetstack-bot jetstack-bot added the approved Indicates a PR has been approved by an approver from all required OWNERS files. label Mar 14, 2024
@jetstack-bot jetstack-bot merged commit c2cecf8 into cert-manager:master Mar 14, 2024
8 checks passed
@wallrj wallrj deleted the bump-go-jose-CVE-2024-28180 branch March 14, 2024 16:00
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
approved Indicates a PR has been approved by an approver from all required OWNERS files. dco-signoff: yes Indicates that all commits in the pull request have the valid DCO sign-off message. kind/cleanup Categorizes issue or PR as related to cleaning up code, process, or technical debt. lgtm Indicates that a PR is ready to be merged. release-note Denotes a PR that will be considered when it comes time to generate release notes. size/M Denotes a PR that changes 30-99 lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants