Skip to content

Fix for OCPBUGS-104441: CVE-2026-69152 - #16937

Open
germanparente wants to merge 2 commits into
openshift:mainfrom
germanparente:fix-CVE-2026-69152-main
Open

Fix for OCPBUGS-104441: CVE-2026-69152#16937
germanparente wants to merge 2 commits into
openshift:mainfrom
germanparente:fix-CVE-2026-69152-main

Conversation

@germanparente

@germanparente germanparente commented Aug 10, 2026

Copy link
Copy Markdown
Contributor

Summary

Fixes CVE-2026-69152 — Denial of Service via unbounded intermediate array allocation in brace-expansion's expand() function.

Resolutions added

frontend/package.json:

  • brace-expansion@^1.1.71.1.18
  • brace-expansion@^2.0.22.1.4
  • brace-expansion@^5.0.55.0.9

dynamic-demo-plugin/package.json:

  • brace-expansion@^5.0.55.0.9

Summary by CodeRabbit

  • Chores
    • Updated package resolution settings to use pinned versions of brace-expansion.
    • Preserved the existing immutable and protobufjs resolutions.
    • No user-facing functionality or public APIs changed.

@openshift-merge-bot

Copy link
Copy Markdown
Contributor

Pipeline controller notification
This repo is configured to use the pipeline controller. Second-stage tests will be triggered either automatically or after lgtm label is added, depending on the repository configuration. The pipeline controller will automatically detect which contexts are required and will utilize /test Prow commands to trigger the second stage.

For optional jobs, comment /test ? to see a list of all defined jobs. To trigger manually all jobs from second stage use /pipeline required command.

This repository is configured in: LGTM mode

@openshift-ci-robot openshift-ci-robot added jira/severity-important Referenced Jira bug's severity is important for the branch this PR is targeting. jira/valid-reference Indicates that this PR references a valid Jira ticket of any type. jira/valid-bug Indicates that a referenced Jira bug is valid for the branch this PR is targeting. labels Aug 10, 2026
@openshift-ci-robot

Copy link
Copy Markdown
Contributor

@germanparente: This pull request references Jira Issue OCPBUGS-104441, which is valid. The bug has been moved to the POST state.

3 validation(s) were run on this bug
  • bug is open, matching expected state (open)
  • bug target version (5.0.0) matches configured target version for branch (5.0.0)
  • bug is in the state New, which is one of the valid states (NEW, ASSIGNED, POST)

The bug has been updated to refer to the pull request using the external bug tracker.

Details

In response to this:

Summary

Fixes CVE-2026-69152 — Denial of Service via unbounded intermediate array allocation in brace-expansion's expand() function.

Resolutions added

frontend/package.json:

  • brace-expansion@^1.1.71.1.18
  • brace-expansion@^2.0.22.1.4
  • brace-expansion@^5.0.55.0.9

dynamic-demo-plugin/package.json:

  • brace-expansion@^5.0.55.0.9

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 requested review from Leo6Leo and jhadvig August 10, 2026 16:38
@openshift-ci openshift-ci Bot added the kind/demo-plugin Related to dynamic-demo-plugin label Aug 10, 2026
@openshift-ci

openshift-ci Bot commented Aug 10, 2026

Copy link
Copy Markdown
Contributor

[APPROVALNOTIFIER] This PR is NOT APPROVED

This pull-request has been approved by: germanparente
Once this PR has been reviewed and has the lgtm label, please assign vojtechszocs 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 Aug 10, 2026

Copy link
Copy Markdown
Contributor

Walkthrough

The package manifests add pinned Yarn resolutions for brace-expansion versions while retaining existing immutable and protobufjs resolutions.

Changes

Dependency resolutions

Layer / File(s) Summary
Pin brace-expansion versions
dynamic-demo-plugin/package.json, frontend/package.json
Both manifests add pinned brace-expansion resolutions. Existing immutable and protobufjs resolutions remain.

Estimated code review effort: 1 (Trivial) | ~2 minutes

Suggested reviewers: logonoff, rhamilto

🚥 Pre-merge checks | ✅ 14 | ❌ 1

❌ Failed checks (1 warning)

Check name Status Explanation Resolution
Description check ⚠️ Warning The description explains the vulnerability and dependency changes but omits most required template sections, including testing, browser conformance, and reviewers. Complete the required template sections, especially analysis, solution details, test setup, test cases, browser conformance, additional information, and reviewers or assignees.
✅ Passed checks (14 passed)
Check name Status Explanation
Title check ✅ Passed The title clearly identifies the Jira issue and the CVE fix, which matches the dependency updates in the pull request.
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 The PR changes only package.json and yarn.lock dependency metadata; no test files or added Ginkgo title declarations exist.
Test Structure And Quality ✅ Passed The pull request changes only package manifests and Yarn lockfiles; it adds no Ginkgo tests, cluster operations, waits, or assertions to review.
Microshift Test Compatibility ✅ Passed The commit changes only package manifests and yarn.lock files; it adds no Ginkgo e2e tests or new OpenShift API usage requiring MicroShift checks.
Single Node Openshift (Sno) Test Compatibility ✅ Passed The pull request changes only package manifests and Yarn lockfiles; it adds no Ginkgo e2e tests or multi-node test assumptions.
Topology-Aware Scheduling Compatibility ✅ Passed The pull request changes only package manifests and Yarn lockfiles; it adds dependency resolutions and introduces no deployment, operator, controller, or scheduling constraints.
Ote Binary Stdout Contract ✅ Passed The commit changes only package manifests and Yarn lockfiles; no OTE binary or OTE suite entry point is present, so the stdout contract is not applicable.
Ipv6 And Disconnected Network Test Compatibility ✅ Passed The diff changes only package.json and yarn.lock files; it adds no Ginkgo e2e tests and no IPv4 or external-connectivity assumptions.
No-Weak-Crypto ✅ Passed The PR changes only package manifests and Yarn lockfiles; exact weak-crypto and crypto API/secret-comparison searches found no matches or source-code changes.
Container-Privileges ✅ Passed The commit changes only package files and lockfiles; it adds no privilege indicators. The existing deployment uses allowPrivilegeEscalation: false and runAsNonRoot: true.
No-Sensitive-Data-In-Logs ✅ Passed The commit changes only package manifests and Yarn lockfiles; added lines contain dependency metadata and no logging calls or sensitive-data fields.
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests

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

@openshift-ci-robot

Copy link
Copy Markdown
Contributor

@germanparente: This pull request references Jira Issue OCPBUGS-104441, which is valid.

3 validation(s) were run on this bug
  • bug is open, matching expected state (open)
  • bug target version (5.0.0) matches configured target version for branch (5.0.0)
  • bug is in the state POST, which is one of the valid states (NEW, ASSIGNED, POST)
Details

In response to this:

Summary

Fixes CVE-2026-69152 — Denial of Service via unbounded intermediate array allocation in brace-expansion's expand() function.

Resolutions added

frontend/package.json:

  • brace-expansion@^1.1.71.1.18
  • brace-expansion@^2.0.22.1.4
  • brace-expansion@^5.0.55.0.9

dynamic-demo-plugin/package.json:

  • brace-expansion@^5.0.55.0.9

Summary by CodeRabbit

  • Chores
  • Updated package resolution settings to use pinned versions of brace-expansion.
  • Preserved the existing immutable and protobufjs resolutions.
  • No user-facing functionality or public APIs changed.

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.

Keep only the brace-expansion resolution in package.json;
revert lockfile churn that downgraded @openshift/dynamic-plugin-sdk.

@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

🧹 Nitpick comments (1)
frontend/package.json (1)

226-228: 🔒 Security & Privacy | 🔵 Trivial

Regenerate and verify the lockfile for these resolutions.

The manifest entries do not prove that CI installs the pinned versions. If this project commits a Yarn lockfile, update its locators and integrity metadata. Confirm the resolved graph, SBOM/provenance, and artifact signing before release. (classic.yarnpkg.com)

As per path instructions, verify exact versions, hashes where supported, OSV advisories, SBOM/provenance, and artifact signing.

🤖 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 `@frontend/package.json` around lines 226 - 228, Regenerate the committed Yarn
lockfile for the three brace-expansion resolutions declared in package.json,
ensuring each locator resolves to the exact pinned version with updated
integrity metadata. Verify the resulting dependency graph, supported hashes, OSV
advisories, SBOM/provenance, and artifact signing before release.

Sources: Path instructions, MCP tools

🤖 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 `@dynamic-demo-plugin/package.json`:
- Line 88: Regenerate dynamic-demo-plugin/yarn.lock from the brace-expansion
dependency pinned to 5.0.9 in dynamic-demo-plugin/package.json, replacing the
vulnerable 5.0.7 entry while retaining valid Yarn checksums. The
frontend/package.json dependency range at lines 226-228 requires no direct
change; ensure the release workflow continues enforcing OSV scanning, SBOM
generation, provenance attestations, and Sigstore/cosign signing.

---

Nitpick comments:
In `@frontend/package.json`:
- Around line 226-228: Regenerate the committed Yarn lockfile for the three
brace-expansion resolutions declared in package.json, ensuring each locator
resolves to the exact pinned version with updated integrity metadata. Verify the
resulting dependency graph, supported hashes, OSV advisories, SBOM/provenance,
and artifact signing before release.
🪄 Autofix

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: Repository: openshift/coderabbit/.coderabbit.yaml

Review profile: CHILL

Plan: Enterprise

Run ID: 0bce3e4e-4328-42a9-8a0d-68793819dcc2

📥 Commits

Reviewing files that changed from the base of the PR and between e2866d6 and d77747d.

⛔ Files ignored due to path filters (2)
  • dynamic-demo-plugin/yarn.lock is excluded by !**/yarn.lock, !**/*.lock
  • frontend/yarn.lock is excluded by !**/yarn.lock, !**/*.lock
📒 Files selected for processing (2)
  • dynamic-demo-plugin/package.json
  • frontend/package.json

"minimatch@^9.0.4": "^9.0.6",
"immutable": "^3.8.3"
"immutable": "^3.8.3",
"brace-expansion@^5.0.5": "5.0.9"

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.

🔒 Security & Privacy | 🟠 Major | ⚡ Quick win

🧩 Analysis chain

🏁 Script executed:

#!/usr/bin/env bash
set -euo pipefail

find . -name yarn.lock -not -path '*/node_modules/*' -print
rg -n -C 3 'brace-expansion@|integrity' \
  --glob 'yarn.lock' \
  --glob '!**/node_modules/**' .

for version in 1.1.18 2.1.4 3.0.6 5.0.9; do
  curl -fsS -X POST \
    -H 'Content-Type: application/json' \
    -d "{\"package\":{\"ecosystem\":\"npm\",\"name\":\"brace-expansion\"},\"version\":\"${version}\"}" \
    https://api.osv.dev/v1/query
done

Repository: openshift/console

Length of output: 8280


🏁 Script executed:

#!/usr/bin/env bash
set -euo pipefail

printf '%s\n' '--- manifests and lockfile headers ---'
sed -n '1,25p' dynamic-demo-plugin/package.json
sed -n '75,95p' dynamic-demo-plugin/package.json
sed -n '1,25p' frontend/package.json
sed -n '215,235p' frontend/package.json
sed -n '1,35p' dynamic-demo-plugin/yarn.lock
sed -n '1,35p' frontend/yarn.lock

printf '%s\n' '--- all brace-expansion lock entries ---'
rg -n -A 9 -B 1 'brace-expansion@' dynamic-demo-plugin/yarn.lock frontend/yarn.lock

printf '%s\n' '--- package-manager and install configuration ---'
git ls-files | rg '(^|/)(packageManager|\\.yarnrc\\.yml|\\.npmrc|yarn\\.config\\.|pnpm-lock\\.yaml|package-lock\\.json|.*\\.github/workflows/.*)$' || true
rg -n -i 'sbom|provenance|attestation|sigstore|cosign|slsa|artifact signing|yarn install|yarn --immutable|yarn --frozen-lockfile' \
  --glob '!**/node_modules/**' \
  --glob '!**/yarn.lock' \
  . || true

printf '%s\n' '--- npm registry integrity metadata ---'
for version in 1.1.18 2.1.4 3.0.6 3.0.7 4.0.0 5.0.7 5.0.9; do
  curl -fsS "https://registry.npmjs.org/brace-expansion/${version}" |
    jq -r '[.version, .dist.tarball, .dist.integrity, .dist.shasum] | `@tsv`'
done

printf '%s\n' '--- OSV results, reduced to affected ranges and fixed versions ---'
for version in 1.1.18 2.1.4 3.0.6 3.0.7 4.0.0 5.0.7 5.0.9; do
  curl -fsS -X POST \
    -H 'Content-Type: application/json' \
    -d "{\"package\":{\"ecosystem\":\"npm\",\"name\":\"brace-expansion\"},\"version\":\"${version}\"}" \
    https://api.osv.dev/v1/query |
    jq -c --arg version "$version" '{version:$version, vulns:([.vulns[]? | {id, severity, affected}])}'
done

Repository: openshift/console

Length of output: 45733


🏁 Script executed:

#!/usr/bin/env bash
set -u

printf '%s\n' '--- build and workflow install modes ---'
sed -n '1,80p' build-demos.sh
sed -n '1,80p' build-frontend.sh
git ls-files '.github/workflows' | head -80
rg -n -i 'yarn( install)?|--immutable|sbom|provenance|attestation|cosign|sigstore|slsa' \
  .github/workflows build-demos.sh build-frontend.sh 2>/dev/null || true

printf '%s\n' '--- exact brace-expansion descriptors and versions ---'
python3 - <<'PY'
import re
from pathlib import Path

for filename in ("dynamic-demo-plugin/yarn.lock", "frontend/yarn.lock"):
    text = Path(filename).read_text()
    print(filename)
    for match in re.finditer(r'(?m)^"?(brace-expansion@[^"]+)"?:\n((?:  .*\n|    .*\n)*)', text):
        block = match.group(0)
        version = re.search(r'(?m)^  version: (.+)$', block)
        resolution = re.search(r'(?m)^  resolution: (.+)$', block)
        print("  descriptor:", match.group(1))
        print("  version:", version.group(1) if version else "MISSING")
        print("  resolution:", resolution.group(1) if resolution else "MISSING")

print("manifest resolution targets:")
for filename in ("dynamic-demo-plugin/package.json", "frontend/package.json"):
    import json
    data = json.loads(Path(filename).read_text())
    print(filename, {k:v for k,v in data.get("resolutions", {}).items()
                     if k.startswith("brace-expansion")})
PY

printf '%s\n' '--- OSV status for available versions ---'
for version in 1.1.18 2.1.4 3.0.6 5.0.7 5.0.9; do
  response="$(curl -fsS -X POST \
    -H 'Content-Type: application/json' \
    -d "{\"package\":{\"ecosystem\":\"npm\",\"name\":\"brace-expansion\"},\"version\":\"${version}\"}" \
    https://api.osv.dev/v1/query)" || {
      printf '%s\n' "$version: query failed"
      continue
    }
  printf '%s ' "$version"
  jq -r 'if .vulns then ([.vulns[] | .id] | join(",")) else "no advisories" end' <<<"$response"
done

printf '%s\n' '--- registry integrity metadata for locked versions ---'
for version in 1.1.18 2.1.4 5.0.7 5.0.9; do
  curl -fsS "https://registry.npmjs.org/brace-expansion/${version}" |
    jq -r --arg v "$version" '[$v, .dist.integrity, .dist.shasum] | `@tsv`' ||
    printf '%s\tmetadata query failed\n' "$version"
done

Repository: openshift/console

Length of output: 2339


🏁 Script executed:

#!/usr/bin/env bash
set -euo pipefail

printf '%s\n' '--- OSV advisory details for the locked vulnerable version ---'
curl -fsS -X POST \
  -H 'Content-Type: application/json' \
  -d '{"package":{"ecosystem":"npm","name":"brace-expansion"},"version":"5.0.7"}' \
  https://api.osv.dev/v1/query |
  jq -c '[.vulns[] | {
    id,
    summary,
    severity,
    published,
    modified,
    affected: [.affected[] | {
      ranges: .ranges,
      database_specific: .database_specific
    }]
  }]'

printf '%s\n' '--- tracked repository automation and supply-chain controls ---'
git ls-files | rg '^\.github/|(^|/)(Makefile|Taskfile.*|cosign|.*sbom.*|.*provenance.*|.*attestation.*)$' || true
rg -n -i 'sbom|provenance|attestation|cosign|sigstore|slsa|artifact signing|osv-scanner|audit|yarn install --immutable' \
  --glob '!**/vendor/**' \
  --glob '!**/node_modules/**' \
  --glob '!**/*.lock' \
  . || true

Repository: openshift/console

Length of output: 7556


Regenerate dynamic-demo-plugin/yarn.lock for brace-expansion@5.0.9.

dynamic-demo-plugin/yarn.lock installs vulnerable 5.0.7. This version is affected by GHSA-mh99-v99m-4gvg and GHSA-rgw5-rvv9-x895. build-demos.sh uses yarn install --immutable, so it cannot update the stale lockfile.

frontend/yarn.lock contains only the patched 1.1.18, 2.1.4, and 5.0.9 entries. Retain Yarn checksums, and enforce OSV scanning, SBOM generation, provenance attestations, and Sigstore/cosign signing for released artifacts.

📍 Affects 2 files
  • dynamic-demo-plugin/package.json#L88-L88 (this comment)
  • frontend/package.json#L226-L228
🤖 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 `@dynamic-demo-plugin/package.json` at line 88, Regenerate
dynamic-demo-plugin/yarn.lock from the brace-expansion dependency pinned to
5.0.9 in dynamic-demo-plugin/package.json, replacing the vulnerable 5.0.7 entry
while retaining valid Yarn checksums. The frontend/package.json dependency range
at lines 226-228 requires no direct change; ensure the release workflow
continues enforcing OSV scanning, SBOM generation, provenance attestations, and
Sigstore/cosign signing.

Sources: Path instructions, MCP tools

@openshift-ci

openshift-ci Bot commented Aug 10, 2026

Copy link
Copy Markdown
Contributor

@germanparente: 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/frontend 2fda1f2 link true /test frontend
ci/prow/analyze 2fda1f2 link true /test analyze

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/severity-important Referenced Jira bug's severity is important for the branch this PR is targeting. jira/valid-bug Indicates that a referenced Jira bug is valid for the branch this PR is targeting. jira/valid-reference Indicates that this PR references a valid Jira ticket of any type. kind/demo-plugin Related to dynamic-demo-plugin

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants