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

Update dependencies to address CVEs #1

Draft
wants to merge 14 commits into
base: v0.34.x
Choose a base branch
from

Conversation

AlexsandroRyan
Copy link
Collaborator

@AlexsandroRyan AlexsandroRyan commented Aug 13, 2024

This pull request aims to address all the CVEs that were reported by Checkmarx tool when executed over this repository.

Previous conversation happened here cometbft#3558

I have so far updated all needed dependencies to fix the CVEs, but there are still some remaining and maybe someone else can help me to get it fixed.

  1. CVE-2021-3538: This is related to the github.com/satori/go.uuid which is a dependency of https://github.com/informalsystems/tm-load-test and we already created a PR here Replace vulnerable satori/go.uuid with google/uuid informalsystems/tm-load-test#221.
  2. CVE-2024-24786: This is one vulnerability related to google.golang.org/protobuf that when we run go mod graph | grep google.golang.org/protobuf, we see a lot of packages using the version that contains the vulnerability, not sure if it's viable to update one by one.
  3. CVE-2024-34478: This is related to github.com/btcsuite/btcd which is a dependency of github.com/btcsuite/btcd/btcutil being used with version lower than 0.24.0. We have also raised a pull request for this Updated btcd dependency of btcutil to address CVE-2024-34478 btcsuite/btcd#2235.

Let us know if this is suficient or if there's a better path for solving any of these quickly.


PR checklist

  • Tests written/updated
  • Changelog entry added in .changelog (we use unclog to manage our changelog)
  • Updated relevant documentation (docs/ or spec/) and code comments
  • Title follows the Conventional Commits spec

Updated the dependency with the command:
go get github.com/btcsuite/btcd/btcutil

Relevant package updated:
go: upgraded github.com/btcsuite/btcd v0.23.0 => v0.23.5-0.20231215221805-96c9fd8078fd
Updated the dependency with the command:
go get go get github.com/moby/buildkit

Relevant package updated:
go: upgraded github.com/moby/buildkit v0.10.4 => v0.15.1
Found the corresponding dependency:
go mod graph | grep github.com/nats-io/nats-server/v2
> github.com/go-kit/[email protected] github.com/nats-io/nats-server/[email protected]

Updated the dependency with the command:
go get github.com/go-kit/kit

The dependency updated after updating:
go mod graph | grep github.com/nats-io/nats-server/v2
> github.com/go-kit/[email protected] github.com/nats-io/nats-server/[email protected]
Change was performed in line 100 of go.mod file in commit 960870c

Checking updated dependency:
go mod graph | grep github.com/emicklei/go-restful
> github.com/containerd/[email protected] github.com/emicklei/go-restful/[email protected]
…2024-23653

We've update the github.com/moby/buildkit to newer version in the
commit 960870c, but then verified there's one dependency using old
buildkit version(this means that CVE-2024-23653 wasn't addressed):
go mod graph | grep github.com/moby/buildkit
> github.com/bufbuild/[email protected] github.com/moby/[email protected]

Updated github.com/bufbuild/buf version to latest and newer version
doesn't use buildkit anymore.
…22-24450

Update of the github.com/go-kit/kit to v0.13.0 in commit
f5787ef addressed the CVE-2022-24450

Check:
go mod graph | grep github.com/nats-io/nats-server/v2
> github.com/go-kit/[email protected] github.com/nats-io/nats-server/[email protected]
Updated the dependency with the command:
go get github.com/adlio/schema

Check:
go mod graph | grep github.com/docker/docker
> github.com/tendermint/tendermint github.com/docker/[email protected]+incompatible
> github.com/adlio/[email protected] github.com/docker/[email protected]+incompatible
> github.com/bufbuild/[email protected] github.com/docker/[email protected]+incompatible
> github.com/bufbuild/[email protected] github.com/docker/[email protected]
> github.com/moby/[email protected] github.com/docker/[email protected]+incompatible
> github.com/moby/[email protected] github.com/docker/[email protected]
Change was performed in line 218 of go.mod file in commit a20047a

Checking updated dependency:
go mod graph | grep github.com/opencontainers/runc
> github.com/adlio/[email protected] github.com/opencontainers/[email protected]
Change was performed in line 218 of go.mod file in commit a20047a

Checking updated dependency:
go mod graph | grep github.com/opencontainers/runc
> github.com/adlio/[email protected] github.com/opencontainers/[email protected]
Change was performed in line 218 of go.mod file in commit a20047a

Checking updated dependency:
go mod graph | grep github.com/opencontainers/runc
> github.com/adlio/[email protected] github.com/opencontainers/[email protected]
@JpOnline JpOnline changed the title Updated github.com/btcsuite/btcd/btcutil to address CVE-2022-44797 Updated dependencies to address CVEs Aug 14, 2024
@JpOnline JpOnline changed the title Updated dependencies to address CVEs Update dependencies to address CVEs Aug 14, 2024
…23651

Run command:
go get github.com/btcsuite/btcd/[email protected]

Output:
go: upgraded github.com/btcsuite/btcd v0.23.5-0.20231215221805-96c9fd8078fd => v0.24.2
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant