Skip to content

Bump golang.org/x/image to v0.42.0 (CVE-2026-33813) - #48345

Merged
lukeheath merged 2 commits into
mainfrom
bump-x-image-cve-2026-33813
Jun 26, 2026
Merged

Bump golang.org/x/image to v0.42.0 (CVE-2026-33813)#48345
lukeheath merged 2 commits into
mainfrom
bump-x-image-cve-2026-33813

Conversation

@lukeheath

@lukeheath lukeheath commented Jun 26, 2026

Copy link
Copy Markdown
Member

Related issue: N/A (dependency security bump)

Summary

Bumps golang.org/x/image from v0.38.0 to v0.42.0 to resolve CVE-2026-33813, a denial-of-service (panic) in the WebP decoder when parsing an image with an invalid, large declared size.

go mod tidy pulled in the transitive minimum-version bumps required by x/image@v0.42.0: x/mod v0.35.0v0.36.0, x/sync v0.20.0v0.21.0, x/text v0.37.0v0.38.0, x/tools v0.44.0v0.45.0.

Exposure assessment

  • Fleet reaches the affected golang.org/x/image/webp decoder via the org-logo upload path (server/fleet/org_logo.goimage.DecodeConfig).
  • The CVE only panics on 32-bit platforms; Fleet server binaries are built for amd64/arm64 only, so deployed Fleet was not practically exploitable. The upload also requires AppConfig:Write (admin) authorization.
  • This bump is primarily to clear the dependency scanner finding.

Checklist for submitter

  • Changes file added for user-visible changes in changes/.

Testing

  • go build ./server/fleet/... ./orbit/pkg/table/app-icons/... passes.
  • go test ./server/fleet/ -run TestValidateOrgLogoBytes passes (covers the WebP/PNG/JPEG/SVG validation path).

Summary by CodeRabbit

  • Bug Fixes
    • Addressed a security issue affecting WebP decoding on certain 32-bit systems by updating the image-processing library.
    • Refreshed several related supporting libraries to newer versions for ongoing stability and compatibility.

Copilot AI review requested due to automatic review settings June 26, 2026 16:27
@lukeheath
lukeheath requested a review from a team as a code owner June 26, 2026 16:27

@claude claude Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Claude Code Review

This repository is configured for manual code reviews. Comment @claude review to trigger a review and subscribe this PR to future pushes, or @claude review once for a one-time review.

Tip: disable this comment in your organization's Code Review settings.

@coderabbitai

coderabbitai Bot commented Jun 26, 2026

Copy link
Copy Markdown
Contributor

Review Change Stack

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Pro

Run ID: 03bdca79-112b-4418-94df-168cc41da50b

📥 Commits

Reviewing files that changed from the base of the PR and between e8e574c and 846a481.

⛔ Files ignored due to path filters (1)
  • go.sum is excluded by !**/*.sum
📒 Files selected for processing (1)
  • go.mod

Walkthrough

The PR updates Go dependency versions, including golang.org/x/image to v0.42.0 and several other golang.org/x/* modules in go.mod.

🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Title check ✅ Passed The title accurately summarizes the main change: bumping golang.org/x/image to v0.42.0 for CVE-2026-33813.
Description check ✅ Passed The description follows the template well, with related issue, summary, checklist, exposure assessment, and testing details filled in.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch bump-x-image-cve-2026-33813

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Actionable comments posted: 1

🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Inline comments:
In `@go.mod`:
- Line 46: The go.mod change unintentionally downgrades
github.com/containerd/containerd from v1.7.33 to v1.7.32, which reintroduces
known HIGH severity vulnerabilities. Revert the containerd version in go.mod
back to v1.7.33 or newer, and then re-run dependency tidying so the module graph
stays aligned; if the lower version is intended, add explicit justification and
risk acceptance in the change discussion.
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Pro

Run ID: 861150ce-e652-4ed4-ac5f-90cafcad66f6

📥 Commits

Reviewing files that changed from the base of the PR and between 005bcdc and e8e574c.

⛔ Files ignored due to path filters (1)
  • go.sum is excluded by !**/*.sum
📒 Files selected for processing (2)
  • changes/47498-bump-x-image-cve-2026-33813
  • go.mod

Comment thread go.mod Outdated

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Warning

  • Copilot's review of this pull request may be incomplete because some of the changed files are excluded by your Copilot content exclusion settings. See Excluding content from Copilot for details.

Pull request overview

Updates Go module dependencies to remediate CVE-2026-33813 by bumping golang.org/x/image to v0.42.0, along with associated go mod tidy dependency graph updates.

Changes:

  • Bump golang.org/x/image to v0.42.0 (and related golang.org/x/* transitive minimums) in go.mod/go.sum.
  • Adjust github.com/containerd/containerd requirement to v1.7.32 (note: this is a downgrade vs the prior v1.7.33).
  • Update go.mod’s ignore list by removing ./apps.

Reviewed changes

Copilot reviewed 1 out of 3 changed files in this pull request and generated 1 comment.

File Description
go.mod Bumps golang.org/x/image and related x/* modules; also changes containerd version and updates the ignore list.
go.sum Updates module checksums to match the new go.mod versions.
changes/47498-bump-x-image-cve-2026-33813 Release-note entry for the dependency/security bump (content excluded by policy).
Files excluded by content exclusion policy (1)
  • changes/47498-bump-x-image-cve-2026-33813
Comments suppressed due to low confidence (1)

go.mod:392

  • go.mod also drops ./apps from the ignore list. If this was an artifact of go mod tidy, consider restoring it (to avoid go tooling traversing non-Go app sources) or at least mentioning the change in the PR summary since it’s unrelated to the x/image CVE bump.
ignore (
	./articles
	./assets
	./docs
	./frontend
	./handbook

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread go.mod
Comment on lines 44 to 47
github.com/cenkalti/backoff/v4 v4.3.0
github.com/clbanning/mxj v1.8.4
github.com/containerd/containerd v1.7.33
github.com/containerd/containerd v1.7.32
github.com/crewjam/saml v0.5.1
@codecov

codecov Bot commented Jun 26, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 67.41%. Comparing base (005bcdc) to head (846a481).
⚠️ Report is 3 commits behind head on main.

Additional details and impacted files
@@            Coverage Diff             @@
##             main   #48345      +/-   ##
==========================================
- Coverage   67.42%   67.41%   -0.01%     
==========================================
  Files        3665     3665              
  Lines      231969   231969              
  Branches    12304    12304              
==========================================
- Hits       156397   156391       -6     
- Misses      61537    61542       +5     
- Partials    14035    14036       +1     
Flag Coverage Δ
backend 69.01% <ø> (-0.01%) ⬇️
backend-activity 85.64% <ø> (ø)

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

Comment thread go.mod
)

ignore (
./apps

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

This should stay AFAICS.

@lucasmrod lucasmrod left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Seems there are some unrelated changes.

@lukeheath

Copy link
Copy Markdown
Member Author

Good catch, thanks. The containerd v1.7.33v1.7.32 downgrade and the removal of ./apps from the ignore list were both unintended artifacts. I had run go mod tidy against a stale base before rebasing onto main, so those stale deltas rode along.

Fixed in 846a481: I reset go.mod/go.sum to main and re-applied only the golang.org/x/image bump. The diff is now limited to x/image v0.42.0 plus the transitive x/mod/x/sync/x/text/x/tools minimums that x/image@v0.42.0 requires. containerd stays at v1.7.33 and ./apps is restored.

@qodo-free-for-open-source-projects

Copy link
Copy Markdown

CI Feedback 🧐

A test triggered by this PR failed. Here is an AI-generated analysis of the failure:

Action: aggregate-result

Failed stage: Check for failures [❌]

Failed test name: main-mysql8.0.44

Failure summary:

The action failed in the status-aggregation step that scans downloaded artifacts for status files
and exits non-zero if any contain fail.
- The file ./main-mysql8.0.44-status/status contained fail,
so the script marked the test job main-mysql8.0.44 as failed.
- The script then exited with code 1
after printing: ❌ One or more test jobs failed: main-mysql8.0.44 (log lines 189–192).

Relevant error logs:
1:  ##[group]Runner Image Provisioner
2:  Hosted Compute Agent
...

126:  Artifact download completed successfully.
127:  Extracting artifact entry: /home/runner/work/fleet/fleet/integration-core-mysql8.0.44-status/status
128:  Extracting artifact entry: /home/runner/work/fleet/fleet/fast-status/status
129:  Extracting artifact entry: /home/runner/work/fleet/fleet/integration-enterprise-mysql8.0.44-status/status
130:  Extracting artifact entry: /home/runner/work/fleet/fleet/mysql-mysql8.0.44-status/status
131:  Artifact download completed successfully.
132:  Artifact download completed successfully.
133:  Artifact download completed successfully.
134:  Extracting artifact entry: /home/runner/work/fleet/fleet/vuln-mysql8.0.44-status/status
135:  Extracting artifact entry: /home/runner/work/fleet/fleet/integration-mdm-mysql8.0.44-status/status
136:  Artifact download completed successfully.
137:  Artifact download completed successfully.
138:  Artifact download completed successfully.
139:  Total of 10 artifact(s) downloaded
140:  Download artifact has finished successfully
141:  ##[group]Run failed_tests=""
142:  �[36;1mfailed_tests=""�[0m
143:  �[36;1mstatus_count=0�[0m
144:  �[36;1m# Find all status files (they are in directories like 'fleetctl-mysql8.0.44-status/status')�[0m
145:  �[36;1mfor status_file in $(find ./ -type f -name 'status'); do�[0m
146:  �[36;1m  status_count=$((status_count + 1))�[0m
147:  �[36;1m  # Extract test name from parent directory (e.g., 'fleetctl-mysql8.0.44-status')�[0m
148:  �[36;1m  test_dir=$(basename $(dirname "$status_file"))�[0m
149:  �[36;1m  # Remove '-status' suffix to get the test name�[0m
150:  �[36;1m  test_name="${test_dir%-status}"�[0m
151:  �[36;1m  status_content=$(cat "$status_file")�[0m
152:  �[36;1m  echo "Processing: $status_file (Test: $test_name) with status content: $status_content"�[0m
153:  �[36;1m  if grep -q "fail" "$status_file"; then�[0m
154:  �[36;1m    echo "  ❌ Test failed: $test_name"�[0m
155:  �[36;1m    failed_tests="${failed_tests}${test_name}, "�[0m
156:  �[36;1m  else�[0m
157:  �[36;1m    echo "  ✅ Test passed: $test_name"�[0m
158:  �[36;1m  fi�[0m
159:  �[36;1mdone�[0m
160:  �[36;1mif [[ $status_count -eq 0 ]]; then�[0m
161:  �[36;1m  echo "❌ ERROR: No status files found! This indicates a workflow issue."�[0m
162:  �[36;1m  exit 1�[0m
163:  �[36;1mfi�[0m
164:  �[36;1mif [[ -n "$failed_tests" ]]; then�[0m
165:  �[36;1m  echo "❌ One or more test jobs failed: ${failed_tests%, }"�[0m
166:  �[36;1m  exit 1�[0m
...

174:  ✅ Test passed: vuln-mysql8.0.44
175:  Processing: ./service-mysql8.0.44-status/status (Test: service-mysql8.0.44) with status content: success
176:  ✅ Test passed: service-mysql8.0.44
177:  Processing: ./integration-core-mysql8.0.44-status/status (Test: integration-core-mysql8.0.44) with status content: success
178:  ✅ Test passed: integration-core-mysql8.0.44
179:  Processing: ./mysql-mysql8.0.44-status/status (Test: mysql-mysql8.0.44) with status content: success
180:  ✅ Test passed: mysql-mysql8.0.44
181:  Processing: ./integration-enterprise-mysql8.0.44-status/status (Test: integration-enterprise-mysql8.0.44) with status content: success
182:  ✅ Test passed: integration-enterprise-mysql8.0.44
183:  Processing: ./integration-mdm-mysql8.0.44-status/status (Test: integration-mdm-mysql8.0.44) with status content: success
184:  ✅ Test passed: integration-mdm-mysql8.0.44
185:  Processing: ./scripts-status/status (Test: scripts) with status content: success
186:  ✅ Test passed: scripts
187:  Processing: ./fast-status/status (Test: fast) with status content: success
188:  ✅ Test passed: fast
189:  Processing: ./main-mysql8.0.44-status/status (Test: main-mysql8.0.44) with status content: fail
190:  ❌ Test failed: main-mysql8.0.44
191:  ❌ One or more test jobs failed: main-mysql8.0.44
192:  ##[error]Process completed with exit code 1.
193:  Post job cleanup.

@lukeheath
lukeheath merged commit 2b50257 into main Jun 26, 2026
38 of 42 checks passed
@lukeheath
lukeheath deleted the bump-x-image-cve-2026-33813 branch June 26, 2026 18:24
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.

3 participants