Skip to content

fix(deps): ship Bun 1.4.4 runtime to drop the compromised eMudhra root - #7606

Merged
lidge-jun merged 1 commit into
lidge-jun:devfrom
LPFchan:fix/bun-runtime-1.4.4
Oct 23, 2026
Merged

lidge-jun merged 1 commit into
lidge-jun:devfrom
LPFchan:fix/bun-runtime-1.4.4

Conversation

@LPFchan

@LPFchan LPFchan commented Oct 23, 2026 •

Copy link
Copy Markdown
Contributor

Summary

Bumps the shipped Bun runtime (dependencies.bun) from 1.4.2 to 1.4.4. The test-runner pin (testRunnerBun 1.4.3) is unchanged.

Why: Bun ships its own root certificate store. 1.4.2 still trusts emSign ECC Root CA - G3, which signed the eight eMudhra intermediate CAs whose private keys turned out to be recoverable from the public certificates (October 2026: Chrome, details). Bun doesn't check Certificate Transparency or revocation, so anyone holding those keys can forge a certificate that the proxy accepts for any upstream, including provider APIs that carry user credentials. Bun 1.4.4 updates its bundled roots to NSS 3.131.1, which drops that root. NODE_USE_SYSTEM_CA / --use-system-ca don't help on 1.4.2, because the bundled roots stay trusted alongside the system store.

Live check against the researchers' test hosts, using fetch from the bundled runtime:

runtime dv-g3b-emudhra.we-have-a-problem.com
1.4.2 (current pin) trusted
1.4.2 + NODE_USE_SYSTEM_CA=1 trusted
1.4.4 rejected (CERT_REVOKED)

Changes:

  • package.json / bun.lock: bun 1.4.2 → 1.4.4 (only the bun and @oven/bun-* entries move)
  • Dockerfile: oven/bun:1.4.4 pinned by its multi-platform index digest sha256:1d22548f…548f1d (resolved from Docker Hub; the same lookup returns the existing 1.4.2 digest exactly)
  • tests/ci-workflows/install-scripts.test.ts: the runtime pin assertion now expects 1.4.4
  • Docs that state the current runtime pin (CONTRIBUTING, docs-site contributing / installation / remote-hub, structure/runtime.md, structure/ops/docs-and-release.md), edited in place, so the structure/ files stay at their 600-line budget

Not changed: .github/ workflow and action comments, which describe the 1.4.2 history, and the testRunnerBun split. Rejoining the two pins is still your lane=all decision, but see the 1.4.4-runner result below.

This touches a dependency-installation surface, so it needs maintainer-sponsored.

Verification

Linux x64 (Ubuntu 24.04), branch based on dev @ 26415a9:

  • bun run typecheck: pass
  • bun run structure:check: pass
  • bun run privacy:scan: pass
  • bun run test tests/ci-workflows/install-scripts.test.ts tests/ci-workflows/ci-scope-gaps.test.ts tests/ci-workflows/test-runner-bun.test.ts tests/ci-workflows/structure-ssot.test.ts tests/service/container-bootstrap.test.ts tests/ci-workflows/ci-review-lanes.test.ts: 223 pass, 0 fail
  • Full bun run test (runner 1.4.3): 51,261 pass / 141 skip / 27 fail on unmodified dev, and the same 27 failures on this branch (none new, none fixed). They are host-environment failures on my machine, mostly PATH-Bun and service-runtime-deferral tests, including the 5 s timeout tracked in [Bug]: ocx-launcher-runtime "missing bundle reaches validated PATH Bun" times out at 5 s under host load #7578.
  • Extra: the same full suite with Bun 1.4.4 as the runner (testRunnerBun flipped only for that run, not committed): 51,259 pass, the same 27 host failures, plus the 2 tests that assert testRunnerBun is 1.4.3. No segfaults or panics. Not a lane=all proof, but the fix(ci,runtime): stop hiding the Bun runtime crash and pin back to 1.4.0 #4821 multi-file --isolate preload crash that kept the runner off 1.4.2 didn't reproduce on Linux.
  • Smoke: src/cli/index.ts start --port 10199 under the bundled 1.4.4 in a throwaway HOME starts, serves /v1/models, and shuts down cleanly.

Not covered locally: macOS and Windows. The 1.4.2 pin exists for #6684's Windows Bun.fetch streaming fix, which 1.4.4 still contains, but a lane=all dispatch would confirm it.

Checklist

  • Scope stays focused and avoids unrelated cleanup.
  • Docs or release notes were updated when needed.
  • Security-sensitive changes were reviewed for secrets, auth, and unsafe defaults.

Summary by CodeRabbit

  • Updates
    • Updated the shipped Bun runtime to version 1.4.4. This includes Windows fetch streaming fixes and updated certificate roots.
    • Updated installation and Docker guidance to reflect the new runtime version. The test runner remains on Bun 1.4.3.

Review readiness checklist

This PR stays in draft until every box below is ticked. Tick all four boxes once the requirements are met:

  • Required local validation passed; commands, results, and any full-suite exception are documented.

  • I pushed my PR to a recent dev commit (at most 10 behind; a maintainer may still ask for the exact tip before merge).

  • I resolved all correct Codex and CodeRabbit findings.

  • My PR is ready for review.

Bun 1.4.2's bundled root store still trusts emSign ECC Root CA - G3, which
signed the eight eMudhra intermediates whose keys are recoverable
(October 2026). Bun 1.4.4 ships NSS 3.131.1 roots without it.
NODE_USE_SYSTEM_CA does not help: bundled roots stay trusted alongside.

Runtime pin only; testRunnerBun stays 1.4.3.
@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Oct 23, 2026 •

Copy link
Copy Markdown

Codex Review Summary

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ✅ Completed 2026-10-23T07:33:35.140908Z c720313 Draft marked ready
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

@coderabbitai

coderabbitai Bot commented Oct 23, 2026

Copy link
Copy Markdown
Contributor

Review in Change Stack →

Note

Currently processing new changes in this PR. This may take a few minutes, please wait...

⚙️ Run configuration
📥 Commits

Reviewing files that changed from the base of the PR and between e033111 and c720313.

⛔ Files ignored due to path filters: 1
  • bun.lock is excluded by !**/*.lock
📒 Files selected for processing: 9
  • CONTRIBUTING.md
  • Dockerfile
  • docs-site/src/content/docs/contributing.md
  • docs-site/src/content/docs/getting-started/installation.md
  • docs-site/src/content/docs/guides/remote-hub.md
  • package.json
  • structure/ops/docs-and-release.md
  • structure/runtime.md
  • tests/ci-workflows/install-scripts.test.ts
+------------------------------------------------------------+
| If you don't finish then you're just busy, not productive. |
+------------------------------------------------------------+
  \
   \     /)/)
        ( '')
        /  |
      o(___)
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create a new PR
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

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.

@github-actions github-actions Bot added the intake: hygiene-blocked Deterministic PR hygiene checks failed label Oct 23, 2026
@github-actions

Copy link
Copy Markdown
Contributor

⚠️ Deterministic hygiene checks failed.

  • unsponsored_surface — This changes an authentication, workflow, release-automation, or dependency surface. MAINTAINERS.md requires security review for these; ask a maintainer to apply maintainer-sponsored once they have reviewed it. Paths: bun.lock, package.json.

@github-actions github-actions Bot added the bug Something isn't working label Oct 23, 2026
@lidge-jun lidge-jun removed the intake: hygiene-blocked Deterministic PR hygiene checks failed label Oct 23, 2026
@github-actions

github-actions Bot commented Oct 23, 2026 •

Copy link
Copy Markdown
Contributor

⏳ DRAFT

  • review readiness checklist open (0/4 boxes ticked).

What to do

  • Tick all four boxes in the PR description once you're done (currently 0/4).

Review readiness checklist

  • ⬜ Required local validation passed; commands, results, and any full-suite exception are documented.
  • ⬜ I pushed my PR to a recent dev commit (at most 10 behind; a maintainer may still ask for the exact tip before merge).
  • ⬜ I resolved all correct Codex and CodeRabbit findings.
  • ⬜ My PR is ready for review.

0/4 boxes ticked.

Automatic draft conversion failed. Please convert this pull request to a draft manually until every box above is ticked.

@github-actions
github-actions Bot marked this pull request as draft October 23, 2026 07:27
@github-actions github-actions Bot added the intake: hygiene-blocked Deterministic PR hygiene checks failed label Oct 23, 2026
@lidge-jun lidge-jun added dependency-change-approved Maintainer approved exceptional dependency or lockfile handling maintainer-sponsored Maintainer sponsors this change to an auth, workflow, release, or dependency surface and removed intake: hygiene-blocked Deterministic PR hygiene checks failed labels Oct 23, 2026
@lidge-jun
lidge-jun marked this pull request as ready for review October 23, 2026 07:28
@lidge-jun
lidge-jun merged commit 7416f18 into lidge-jun:dev Oct 23, 2026
10 of 16 checks passed

@chatgpt-codex-connector chatgpt-codex-connector 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.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: c720313916

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

recovery, the launcher can use an executable Bun from an absolute PATH directory if its
stable version has the pinned major and a minor at least the pinned minor. With the current
1.4.2 dependency, that means 1.4.0 or newer within major 1. Bounded version-policy and identity
1.4.4 dependency, that means 1.4.0 or newer within major 1. Bounded version-policy and identity

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

P1 Badge Reject Bun 1.4.2 in the PATH fallback

When the bundled binary is unavailable after a blocked or failed postinstall, bin/ocx.mjs:1069 sends this 1.4.4 pin to findPathBun, but src/lib/bun-path-runtime.mjs:128 only compares major and minor, so a PATH Bun 1.4.2 is still accepted. That runtime retains the compromised CA this update is meant to remove, so affected npm/pnpm installs can still accept forged provider TLS certificates while sending credentials; enforce a 1.4.4 patch floor in the fallback and adjust the acceptance tests/docs.

AGENTS.md reference: AGENTS.md:L446-L452

Useful? React with 👍 / 👎.

Comment thread package.json
"@modelcontextprotocol/sdk": "^1.32.1",
"@napi-rs/keyring": "1.3.0",
"bun": "1.4.2",
"bun": "1.4.4",

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

P1 Badge Update the privileged cleanup workflow to Bun 1.4.4

In the scheduled cleanup job, .github/workflows/cleanup-orphaned-workflows.yml:37-45 still installs Bun 1.4.2 and then runs scripts/ci/cleanup-orphaned-workflows.mjs with an actions:write GITHUB_TOKEN; that script sends the token as a Bearer header via Bun fetch to api.github.com. Because 1.4.2 retains the compromised root, this credential-bearing path remains vulnerable despite the runtime bump; resolve the shared 1.4.4 runtime pin or update this hardcoded setup.

AGENTS.md reference: AGENTS.md:L446-L452

Useful? React with 👍 / 👎.

recovery, the launcher can use an executable Bun from an absolute PATH directory if its
stable version has the pinned major and a minor at least the pinned minor. With the current
1.4.2 dependency, that means 1.4.0 or newer within major 1. Bounded version-policy and identity
1.4.4 dependency, that means 1.4.0 or newer within major 1. Bounded version-policy and identity

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

P2 Badge Update the Korean installation runtime pin

The published Korean installation page at docs-site/src/content/docs/ko/getting-started/installation.md:29-30 still tells readers that the current dependency is 1.4.2, while this English canonical page and package.json now say 1.4.4. Update that locale in the same change so users are not told the package still ships the vulnerable runtime.

AGENTS.md reference: docs-site/AGENTS.md:L9-L10

Useful? React with 👍 / 👎.

luvs01 commented Oct 23, 2026

Copy link
Copy Markdown
Collaborator

Additional Windows verification supports the shipped 1.4.4 update.

Compared official Bun 1.4.3+c6da4a4d3 and 1.4.4+38afee6c8 on Windows x64, with source 88f8d21b0b7e99d82523f97da84183cd221c1bdd and lock blob 1617d2a51cd83cee1478e61b5197097d12a0f1d6 held constant. The 1.4.4 executable matched the official release archive/checksums.

  • Non-CA self-signed certificates explicitly trusted through ca or NODE_EXTRA_CA_CERTS worked with fetch/native WSS, directly and through a loopback HTTP CONNECT proxy. The corresponding trusted-positive cases failed on 1.4.3.
  • Untrusted certificates remained rejected. A separately trusted CA chain verified successful connections plus rejection of expired and hostname-mismatched leaves on both versions.
  • ws top-level ca and node-fetch HTTPS Agent CA cases also changed from failure to success.
  • All 25 candidate matrix rows passed. Both versions passed 16 Windows-plan tests, two CA-environment propagation tests, TypeScript checking, and the actual CLI-entry JS bundle build; bundle hashes matched.

TLS verification stayed enabled. These are isolated fixture measurements; the environment-propagation mocks are not counted as TLS evidence. Two 1.4.3 WSS negative cases returned only a generic TLS error, so their specific certificate failure reason remains unproven.

This does not qualify a test-runner pin change: full multi-file/--isolate lanes, Linux/macOS, performance, native app packaging and production transport E2E were not tested. No global CA store, live app or runtime configuration was changed.

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

Labels

bug Something isn't working dependency-change-approved Maintainer approved exceptional dependency or lockfile handling maintainer-sponsored Maintainer sponsors this change to an auth, workflow, release, or dependency surface

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants