Skip to content

[master] MGMT-24598: CVE-2026-42306 Bump assisted-service dep to pick up docker v28.5.2 - #2219

Open
shay23bra wants to merge 2 commits into
openshift:masterfrom
shay23bra:as-bump-docker-master
Open

[master] MGMT-24598: CVE-2026-42306 Bump assisted-service dep to pick up docker v28.5.2#2219
shay23bra wants to merge 2 commits into
openshift:masterfrom
shay23bra:as-bump-docker-master

Conversation

@shay23bra

@shay23bra shay23bra commented Jul 26, 2026

Copy link
Copy Markdown
Contributor

Bump assisted-service dependency to latest commit which includes docker/docker v28.5.2, fixing CVE-2026-42306.

Summary by CodeRabbit

  • Chores
    • Updated application dependencies to newer versions, including networking, observability, and container-related tooling.
    • Refreshed service API and client integrations to newer revisions.
  • Tests
    • Improved the unit test workflow to consistently run in Go module mode, while preserving existing failure handling behavior.

@openshift-ci-robot openshift-ci-robot added the jira/valid-reference Indicates that this PR references a valid Jira ticket of any type. label Jul 26, 2026
@openshift-ci-robot

openshift-ci-robot commented Jul 26, 2026

Copy link
Copy Markdown

@shay23bra: This pull request references MGMT-24598 which is a valid jira issue.

Warning: The referenced jira issue has an invalid target version for the target branch this PR targets: expected the vulnerability to target the "5.0.0" version, but no target version was set.

Details

In response to this:

Bump assisted-service dependency to latest commit which includes docker/docker v28.5.2, fixing CVE-2026-42306.

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the openshift-eng/jira-lifecycle-plugin repository.

@openshift-ci openshift-ci Bot added the size/XXL Denotes a PR that changes 1000+ lines, ignoring generated files. label Jul 26, 2026
@openshift-ci

openshift-ci Bot commented Jul 26, 2026

Copy link
Copy Markdown

[APPROVALNOTIFIER] This PR is NOT APPROVED

This pull-request has been approved by: shay23bra
Once this PR has been reviewed and has the lgtm label, please assign romfreiman for approval. For more information see the Code Review Process.

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

Details 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

@coderabbitai

coderabbitai Bot commented Jul 26, 2026

Copy link
Copy Markdown

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Repository: openshift/coderabbit/.coderabbit.yaml

Review profile: CHILL

Plan: Enterprise

Run ID: 3a332c4c-0c9e-4554-905b-b65c4d03c105

📥 Commits

Reviewing files that changed from the base of the PR and between d1e6e38 and d9d5058.

📒 Files selected for processing (1)
  • Makefile

Walkthrough

The PR updates direct and indirect Go dependencies, refreshes assisted-service and OCM API replacement pins, and applies GOFLAGS=-mod=mod to unit-test execution and package discovery.

Changes

Dependency and testing updates

Layer / File(s) Summary
Go dependency and replacement refresh
go.mod
Direct and indirect modules are upgraded, added, or removed, including assisted-service, container tooling, database drivers, telemetry, and golang.org/x/* packages; replacement pins are refreshed.
Module-mode unit tests
Makefile
The unit-test target applies GOFLAGS=-mod=mod to test execution and default package discovery while preserving failure cleanup.

Estimated code review effort: 2 (Simple) | ~10 minutes

Suggested reviewers: omertuc, omer-vishlitzky


Important

Pre-merge checks failed

Please resolve all errors before merging. Addressing warnings is optional.

❌ Failed checks (1 error)

Check name Status Explanation Resolution
No-Weak-Crypto ❌ Error FAIL: The PR adds vendor/github.com/jackc/pgx/v5/pgproto3/authentication_md5_password.go, which explicitly uses MD5 for PostgreSQL auth. Remove or avoid vendoring the MD5 auth path, or document an explicit security exception if the protocol compatibility is required.
✅ Passed checks (14 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title accurately reflects the main change: bumping assisted-service to address CVE-2026-42306 via docker v28.5.2.
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.
Stable And Deterministic Test Names ✅ Passed Only Makefile changed; no Ginkgo tests or titles were added/modified, so no unstable test names were introduced.
Test Structure And Quality ✅ Passed PR only changes Makefile/go.mod/vendor; no Ginkgo test code was added or modified, so this test-quality check is not applicable.
Microshift Test Compatibility ✅ Passed Only Makefile changed; no Ginkgo/e2e tests or MicroShift-unsafe OpenShift APIs were added or modified.
Single Node Openshift (Sno) Test Compatibility ✅ Passed PASS: The PR only updates dependencies and the unit-test Makefile target; no Ginkgo e2e tests or SNO-sensitive test files were added.
Topology-Aware Scheduling Compatibility ✅ Passed Only a Makefile test flag changed; no manifests, operators, or controllers were modified, so no topology-aware scheduling constraints were introduced.
Ote Binary Stdout Contract ✅ Passed PASS: The PR only changes Makefile; no main/TestMain/BeforeSuite/RunSpecs code or stdout writes were modified.
Ipv6 And Disconnected Network Test Compatibility ✅ Passed This PR only changes Makefile; no new or modified Ginkgo/e2e tests were added, so no IPv4 or external-connectivity compatibility issue applies.
Container-Privileges ✅ Passed PR changes only go.mod, Makefile, and vendored deps; no Kubernetes/container manifests were modified and no privilege flags appear in the diff.
No-Sensitive-Data-In-Logs ✅ Passed The PR only changes module versions and a Makefile test flag; no logging code or sensitive literals were added.
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests

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

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Actionable comments posted: 2

🤖 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 70: Update the github.com/docker/docker dependency declaration to version
29.5.1 or newer so it is no longer affected by CVE-2026-42306; if Docker
functionality is intentionally unreachable, document that exception instead of
leaving the vulnerable version unchanged.
- Line 98: Update the github.com/jackc/pgx/v5 dependency declaration in go.mod
from v5.6.0 to v5.9.0 or later, ensuring the resolved module metadata remains
consistent with the upgraded version.
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

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

Comment thread go.mod
github.com/docker/distribution v2.8.2+incompatible // indirect
github.com/docker/docker v27.3.1+incompatible // indirect
github.com/docker/go-connections v0.5.0 // indirect
github.com/docker/docker v28.5.2+incompatible // indirect

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

🔒 Security & Privacy | 🟠 Major | ⚡ Quick win

🧩 Analysis chain

🏁 Script executed:

sed -n '60,80p' go.mod

python3 - <<'PY'
import json, urllib.request
url = "https://api.osv.dev/v1/vulns/UBUNTU-CVE-2026-42306"
try:
    with urllib.request.urlopen(url, timeout=20) as r:
        data = json.load(r)
    print(json.dumps({
        "id": data.get("id"),
        "summary": data.get("summary"),
        "affected": data.get("affected", []),
    }, indent=2)[:12000])
except Exception as e:
    print(f"ERROR: {e}")
PY

Repository: openshift/assisted-installer

Length of output: 1452


🌐 Web query:

OSV UBUNTU-CVE-2026-42306 Docker Engine 28.5.2 fixed in 29.5.1 github.com/docker/docker

💡 Result:

CVE-2026-42306 is a security vulnerability affecting Docker Engine and Moby Daemon [1][2]. It involves a race condition that occurs during the setup of a bind mount for the docker cp command [3][4]. A malicious container can exploit this race condition by replacing a destination path (or a parent path component) with a symbolic link after the mount point is created but before the mount syscall is executed [3][4]. This allows the container to redirect the bind mount target to an arbitrary path on the host, which can result in host file overwrites (if the volume is writable) or a denial of service (if the host path is masked by a read-only mount) [3][4]. The vulnerability is addressed in the following versions: - Docker Engine: Fixed in version 29.5.1 (affected versions include 28.5.2 and prior) [1][2][5]. - Moby Daemon: Fixed in version 2.0.0-beta.14 (affected versions include those prior to this release) [1][2][5]. To exploit this, an attacker must have a container with at least one volume mount, and a process within that container must be able to rapidly create and swap symlinks at the mount destination [3][4]. The vulnerability is triggered when an operator initiates a docker cp operation (or calls related API endpoints like PUT /containers/{id}/archive or HEAD /containers/{id}/archive) into the affected container [3][4].

Citations:


🏁 Script executed:

# Show the module context and any imports/usages of github.com/docker/docker
sed -n '1,120p' go.mod
printf '\n--- imports/usages ---\n'
rg -n 'github\.com/docker/docker|from Docker|docker/client|docker/api' . -g '!**/vendor/**'

Repository: openshift/assisted-installer

Length of output: 7223


Bump github.com/docker/docker past v28.5.2
OSV marks 28.5.2 and earlier as affected by CVE-2026-42306; the fix is in 29.5.1. If Docker functionality is intentionally unreachable here, document that exception.

🧰 Tools
🪛 OSV Scanner (2.4.0)

[HIGH] 70-70: github.com/docker/docker 28.5.2+incompatible: Moby has an Off-by-one error in its plugin privilege validation in github.com/docker/docker

(GO-2026-4883)


[HIGH] 70-70: github.com/docker/docker 28.5.2+incompatible: Moby has AuthZ plugin bypass when provided oversized request bodies in github.com/docker/docker

(GO-2026-4887)


[HIGH] 70-70: github.com/docker/docker 28.5.2+incompatible: Docker: Race condition in docker cp allows bind mount redirection to host path in github.com/docker/docker

(GO-2026-5617)


[HIGH] 70-70: github.com/docker/docker 28.5.2+incompatible: Docker: Race condition in docker cp allows creation of arbitrary empty files on the host via symlink swap in github.com/docker/docker

(GO-2026-5668)


[HIGH] 70-70: github.com/docker/docker 28.5.2+incompatible: Docker: 'PUT /containers/{id}/archive' executes container binary on the host in github.com/docker/docker

(GO-2026-5746)


[HIGH] 70-70: github.com/docker/docker 28.5.2+incompatible: Moby has an Off-by-one error in its plugin privilege validation

(GHSA-pxq6-2prw-chj9)


[HIGH] 70-70: github.com/docker/docker 28.5.2+incompatible: Docker: Race condition in docker cp allows bind mount redirection to host path

(GHSA-rg2x-37c3-w2rh)


[HIGH] 70-70: github.com/docker/docker 28.5.2+incompatible: Docker: Race condition in docker cp allows creation of arbitrary empty files on the host via symlink swap

(GHSA-vp62-88p7-qqf5)


[HIGH] 70-70: github.com/docker/docker 28.5.2+incompatible: Moby has AuthZ plugin bypass when provided oversized request bodies

(GHSA-x744-4wpc-v9h2)


[HIGH] 70-70: github.com/docker/docker 28.5.2+incompatible: Docker: PUT /containers/{id}/archive executes container binary on the host

(GHSA-x86f-5xw2-fm2r)

🤖 Prompt for 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.

In `@go.mod` at line 70, Update the github.com/docker/docker dependency
declaration to version 29.5.1 or newer so it is no longer affected by
CVE-2026-42306; if Docker functionality is intentionally unreachable, document
that exception instead of leaving the vulnerable version unchanged.

Source: Linters/SAST tools

Comment thread go.mod
github.com/jackc/pgtype v1.14.4 // indirect
github.com/jackc/pgx/v4 v4.18.3 // indirect
github.com/jackc/pgservicefile v0.0.0-20240606120523-5a60cdf6a761 // indirect
github.com/jackc/pgx/v5 v5.6.0 // indirect

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

🔒 Security & Privacy | 🔴 Critical | ⚡ Quick win

🧩 Analysis chain

🏁 Script executed:

#!/bin/bash
set -euo pipefail

printf '--- go.mod excerpt ---\n'
nl -ba go.mod | sed -n '80,120p'

printf '\n--- direct references to pgx/v5 ---\n'
rg -n 'github.com/jackc/pgx/v5|pgx/v5' . -g '!**/vendor/**' || true

printf '\n--- module graph entries if available in repo metadata ---\n'
git ls-files '*go.sum' '*go.mod' | sed -n '1,20p'

Repository: openshift/assisted-installer

Length of output: 257


🏁 Script executed:

#!/bin/bash
set -euo pipefail

echo '--- go.mod excerpt ---'
nl -ba go.mod | sed -n '80,120p'

echo
echo '--- direct references to pgx/v5 ---'
rg -n 'github.com/jackc/pgx/v5|pgx/v5' . -g '!**/vendor/**' || true

echo
echo '--- go.sum occurrences ---'
rg -n 'github.com/jackc/pgx/v5' go.sum || true

Repository: openshift/assisted-installer

Length of output: 229


🏁 Script executed:

#!/bin/bash
set -euo pipefail

echo '--- go.mod excerpt (lines 80-120) ---'
awk 'NR>=80 && NR<=120 { printf "%5d  %s\n", NR, $0 }' go.mod

echo
echo '--- direct references to pgx/v5 in repository ---'
rg -n 'github.com/jackc/pgx/v5|pgx/v5' . -g '!**/vendor/**' || true

echo
echo '--- go.sum occurrences ---'
rg -n 'github.com/jackc/pgx/v5' go.sum || true

Repository: openshift/assisted-installer

Length of output: 3100


🌐 Web query:

OSV GO-2026-4771 github.com/jackc/pgx/v5 v5.6.0 fixed versions v5.9.0 v5.9.2

💡 Result:

The vulnerability GO-2026-4771 (also identified as CVE-2026-33815 and GHSA-xgrm-4fwx-7qm8) is a memory-safety issue in github.com/jackc/pgx/v5 that affects versions prior to v5.9.0 [1][2][3]. Although initial automated vulnerability reports and some security databases were delayed in reflecting the fix, it has been confirmed that the vulnerability is patched starting in version v5.9.0 [4]. The fix involves bounds checking and input validation in the pgproto3 package, specifically within Backend.Receive, Bind.Decode, and FunctionCall.Decode [1][4]. The version v5.9.0, as well as subsequent releases like v5.9.1 and v5.9.2, contain these security fixes [4][5][6]. Users of pgx/v5 are advised to update to at least version v5.9.0 to remediate this vulnerability [4][3].

Citations:


🌐 Web query:

GO-2026-4771 severity pgx/v5 OSV critical high

💡 Result:

GO-2026-4771 refers to a memory-safety vulnerability in the github.com/jackc/pgx/v5 Go module, specifically within the pgproto3 sub-package [1][2]. Key details include: - Severity: This vulnerability is classified as critical, with a CVSS v3.1 score of 9.8 [3][4][5]. - Affected Versions: Versions of github.com/jackc/pgx/v5 prior to v5.9.0 are affected [1][3]. - Resolution: The issue was addressed and fixed in version 5.9.0 [1][6][4]. - Vulnerability ID: It is also tracked as CVE-2026-33815 and GHSA-xgrm-4fwx-7qm8 [1][7][3]. The vulnerability affects specific routines, namely Backend.Receive and Bind.Decode [1][7]. It was officially published on April 7, 2026 [1][3]. Users are advised to upgrade to version 5.9.0 or later to remediate this vulnerability [1][6].

Citations:


Upgrade github.com/jackc/pgx/v5 to v5.9.0 or later. go.mod:98 pins v5.6.0, which is affected by the critical GO-2026-4771 memory-safety vulnerability.

🧰 Tools
🪛 OSV Scanner (2.4.0)

[CRITICAL] 98-98: github.com/jackc/pgx/v5 5.6.0: CVE-2026-33815 in github.com/jackc/pgx

(GO-2026-4771)


[CRITICAL] 98-98: github.com/jackc/pgx/v5 5.6.0: CVE-2026-33816 in github.com/jackc/pgx

(GO-2026-4772)


[CRITICAL] 98-98: github.com/jackc/pgx/v5 5.6.0: SQL Injection via placeholder confusion with dollar quoted string literals in github.com/jackc/pgx

(GO-2026-5004)


[CRITICAL] 98-98: github.com/jackc/pgx/v5 5.6.0: Memory-safety vulnerability in github.com/jackc/pgx/v5.

(GHSA-9jj7-4m8r-rfcm)


[CRITICAL] 98-98: github.com/jackc/pgx/v5 5.6.0: pgx: SQL Injection via placeholder confusion with dollar quoted string literals

(GHSA-j88v-2chj-qfwx)


[CRITICAL] 98-98: github.com/jackc/pgx/v5 5.6.0: pgx contains memory-safety vulnerability

(GHSA-xgrm-4fwx-7qm8)

🤖 Prompt for 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.

In `@go.mod` at line 98, Update the github.com/jackc/pgx/v5 dependency declaration
in go.mod from v5.6.0 to v5.9.0 or later, ensuring the resolved module metadata
remains consistent with the upgraded version.

Source: Linters/SAST tools

@codecov

codecov Bot commented Jul 26, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 48.82%. Comparing base (e4afa40) to head (d9d5058).

Additional details and impacted files

Impacted file tree graph

@@           Coverage Diff           @@
##           master    #2219   +/-   ##
=======================================
  Coverage   48.82%   48.82%           
=======================================
  Files          20       20           
  Lines        4397     4397           
=======================================
  Hits         2147     2147           
  Misses       2026     2026           
  Partials      224      224           
🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

The Dockerfile already builds with GOFLAGS=-mod=mod. Align unit tests
to use the same mode, avoiding issues with vendored packages that
have subdirectories matching .gitignore patterns (e.g. build/).
@openshift-ci

openshift-ci Bot commented Jul 27, 2026

Copy link
Copy Markdown

@shay23bra: The following tests failed, say /retest to rerun all failed tests or /retest-required to rerun all mandatory failed tests:

Test name Commit Details Required Rerun command
ci/prow/verify-deps d9d5058 link true /test verify-deps
ci/prow/images d9d5058 link true /test images
ci/prow/okd-scos-images d9d5058 link true /test okd-scos-images
ci/prow/e2e-agent-compact-ipv4 d9d5058 link true /test e2e-agent-compact-ipv4

Full PR test history. Your PR dashboard.

Details

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes-sigs/prow repository. I understand the commands that are listed here.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

jira/valid-reference Indicates that this PR references a valid Jira ticket of any type. size/XXL Denotes a PR that changes 1000+ lines, ignoring generated files.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants