[2.13] fix cves in docker client library + go-jwt + bump golang version + bump base image#371
Merged
thatmidwesterncoder merged 2 commits intoJun 4, 2026
Conversation
There was a problem hiding this comment.
Pull request overview
This PR is a maintenance/security update for the rancher/machine build and runtime artifacts, intended to reduce the reported CVE count by updating the base image and key Go dependencies (Docker client library, JWT), and by bumping the Go toolchain patch version.
Changes:
- Bump SUSE BCI base image version used by
package/Dockerfilefrom15.6to15.7. - Update
github.com/docker/dockerdependency tov28.5.2+incompatibleand adjust Docker client code to use the newer pull options type. - Update
github.com/golang-jwt/jwt/v4tov4.5.2and bump the Go toolchain patch version (go1.24.7→go1.24.12).
Reviewed changes
Copilot reviewed 3 out of 4 changed files in this pull request and generated no comments.
| File | Description |
|---|---|
| package/Dockerfile | Bumps the BCI base image version used for building/packaging. |
| libmachine/mcndockerclient/docker_client.go | Adjusts Docker ImagePull options type after Docker library bump. |
| go.mod | Updates Docker and JWT dependencies and bumps Go toolchain patch version; adds new indirect deps. |
| go.sum | Updates module checksums to match the dependency bumps. |
Comments suppressed due to low confidence (1)
libmachine/mcndockerclient/docker_client.go:60
cli.ImagePullreturns a streamed response body that should be fully consumed and closed. Currently the code discards the reader and immediately proceeds toContainerCreate, which can both leak resources and race with the pull (container creation may happen before the image is actually present).
ctx := context.Background()
_, err = cli.ImagePull(ctx, config.Image, image.PullOptions{})
if err != nil {
return fmt.Errorf("unable to pull image: %s", err)
}
resp, err := cli.ContainerCreate(ctx, config, hostConfig, nil, nil, name)
if err != nil {
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
HarrisonWAffel
approved these changes
Jun 3, 2026
124fdae to
dae5cf6
Compare
HarrisonWAffel
approved these changes
Jun 4, 2026
snasovich
approved these changes
Jun 4, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Issue: rancher/rancher#55285
Parent Issue: rancher/rancher#55280
Bumping a few things to lower the CVE count, notably: