Skip to content

Security: enforce trust-store floors and upgrade production dependencies - #22

Merged
battman21 merged 14 commits into
mainfrom
cursor/security-trust-store-node-564b
Oct 22, 2026
Merged

battman21 merged 14 commits into
mainfrom
cursor/security-trust-store-node-564b

Conversation

@battman21

@battman21 battman21 commented Oct 22, 2026 •

Copy link
Copy Markdown
Owner

Summary

  • Problem: Images and CI floated unfixed Node, Go, pip, and certifi trust material. Node's Brotli decoder and the eMudhra CA (CVE-2026-111943 / RUSTSEC-2026-0382, CVE-2026-111497) are fixed only in current vendor runtimes. Debian bookworm OpenSSL is still vulnerable to CVE-2026-84782.
  • What changed: Minimum floors plus build-time checks, not exact pins or digest pins. Images move to Debian 13 trixie floating tags (node:22-trixie, node:22-trixie-slim, golang:1.27-trixie, debian:trixie-slim) and run apt-get upgrade. Ubuntu 24.04 install images stay. CI uses setup-node 22.x with check-latest: true. engines is >=22.23.4 <23 || >=24.22.1 <25 || >=26.12.1 with engine-strict=true. The runtime guard still rejects Node 18, 20, 23, and 25. pip and certifi stay >= floors. ca-certificates, OpenSSL, and (on Ubuntu 24.04) curl are compared per codename; bookworm fails closed. Go language line stays go 1.26.10 and the Docker toolchain is Go 1.27. pnpm is 10.34.7 (HIGH floor 10.34.5). Production dependencies move to current releases, including qs 6.16.1, DOMPurify 3.4.17, sanitize-html 2.18.1, and express 5.3.0.
  • What did not change: Product version 2026.2.16. @buape/carbon 0.14.0. Generated docs/zh-CN/**. The installer default in the sibling openclaw.ai repo. Bun (no vendor fix; still installed as latest after the CA upgrade). express 4.22.1 stays where a parent still requires 4.x (no in-window advisory; direct dependency is 5.3.0). @mariozechner/pi-coding-agent 0.52.12 stays because the audit high has no patched release.

Change Type (select all)

  • Security hardening
  • Docs
  • Chore/infra

Scope (select all touched areas)

  • Gateway / orchestration
  • CI/CD / infra

Linked Issue/PR

User-visible / Behavior Changes

  • Default sandbox image tag is openclaw-sandbox:trixie-slim (browser and common tags follow). Existing configs that set the old bookworm-slim tag need to rebuild and point at the trixie tag.
  • Gateway and CLI still refuse Node below 22.23.4 on the 22 line, below 24.22.1 on the 24 line, and below 26.12.1 on the 26 line. npm engines now also rejects the 23 and 25 lines.
  • Docker and CI fail the build when Node, Go, pnpm, pip, certifi, ca-certificates, or OpenSSL is below the floor. Tags are not digest-pinned.
  • Sandbox images copy official Node 22 and Go 1.27 instead of Debian nodejs / golang-go. The browser sandbox replaces Debian Node 18 (pulled in by noVNC) with that official Node binary.
  • simple-git is 4.0.2 with patches/simple-git@4.0.2.patch so node-llama-cpp can still import the default export. Corepack packageManager is the exact pin pnpm@10.34.7.

Security / Threat Model

  • Trust stores: Node, Go, pip, certifi, and distro ca-certificates each bundle their own roots. A host CA update does not fix them.
  • Bookworm OpenSSL 3.0.22-1~deb12u1 does not include CVE-2026-84782. Trixie floor is openssl 3.5.7-1~deb13u3 and ca-certificates 20250419+deb13u1.
  • glibc CVEs remain unfixed on both bookworm and trixie (Debian tracker, no DSA). Rebuild weekly on the latest trixie tag.
  • Bun still trusts emSign. It is installed only after the distro trust store is current, and it is not the runtime for the gateway process (node openclaw.mjs).
  • Fly (fly.toml builds Dockerfile) and Render (render.yaml docker) need an image rebuild and redeploy, not only a process restart. Merging to main does not deploy either platform. It does run .github/workflows/docker-release.yml, which publishes images to GHCR.

Tests / Verification

Local proof on 5765dc974b5d8476063a42617d9a4d3011031923 (host Node v22.23.4, pnpm 10.34.7). GitHub checks on this fork for that SHA are Workflow Sanity (no-tabs) and Sandbox Common Smoke. The full ci.yml suite does not complete here, so the counts below are from the local run.

  • OPENCLAW_TEST_VM_FORKS=0 OPENCLAW_TEST_PROFILE=low node scripts/test-parallel.mjs exited 0.
    • unit (vitest.unit.config.ts, maxWorkers 2): 674 files, 5665 tests passed
    • extensions (vitest.extensions.config.ts, maxWorkers 1): 109 files, 1093 tests passed, 1 skipped
    • gateway (vitest.gateway.config.ts, forks, maxWorkers 1): 46 files, 435 tests passed
    • total: 829 files, 7193 passed, 1 skipped
  • Every image below was rebuilt on that SHA. Remote-base images used docker build --pull --no-cache. Smoke is an outbound fetch of https://example.com (HTTP 200). Node images that ship npm report npm 12.2.1 and Node v22.23.4. openclaw-cleanup-smoke entrypoint (build, reset, uninstall) printed OK.
  • openclaw-sandbox-common uses local base openclaw-sandbox:trixie-slim, so --pull does not apply to that tag. node:22-trixie-slim and golang:1.27-trixie were pulled, then the image was built --no-cache. Result: Node v22.23.4, npm 12.2.1, go1.27.3, TLS 200.
  • The browser sandbox copies only the Node binary. npm is absent. curl as sandbox and node fetch both returned TLS 200. Node is v22.23.4.
image build id smoke
openclaw-sandbox:trixie-slim --pull --no-cache sha256:50fbbfebc66ed1dbeae5d9287262b0d6e5c75d85b95f937e8c841f9c4ba9c17e curl as sandbox, TLS 200
openclaw-sandbox-browser:trixie-slim --pull --no-cache sha256:e8e869e7762f283eae022ee4e33a00fd181941c159645117dadcfc327f7b2f2e curl TLS 200, node v22.23.4 TLS 200, no npm
openclaw-install-nonroot:floor --pull --no-cache sha256:a97a54f6c94aaab183c3ee35b49314580e7e35e763e7d0f276b9782fb17c62dc curl as app, TLS 200
openclaw-install-smoke:floor --pull --no-cache sha256:85b62d6447b462d19f5435a54db0b25f9c49545d9e9f3f7087f8e1431d7eed8b npm 12.2.1, TLS 200
openclaw-install-e2e:floor --pull --no-cache sha256:e9b15d8283557d3db27680f48c26465f309a721d5c45e5d3a3557439479b1e6d npm 12.2.1, TLS 200
openclaw-cleanup-smoke:floor --pull --no-cache sha256:9506efe711309c88707046f7bbf0fe173d6e6766b77e1ea1775c47c76b5d14b2 npm 12.2.1, TLS 200, entrypoint OK
openclaw-e2e:floor --pull --no-cache sha256:9ef700f0eb326c4c88a387a67e5328fa35bbe719f1ce67ed207275345051a019 npm 12.2.1, node v22.23.4, TLS 200
openclaw-e2e-qr:floor --pull --no-cache sha256:80d7ad1021e79251bf1af3244c788ff33c155f56584dd887c45122894893fc18 npm 12.2.1, TLS 200
openclaw:floor --pull --no-cache sha256:7011f46939b82dacd69b08a9e41b19fe9adf7206c9b1524faf6cba3233c42aef npm 12.2.1, node v22.23.4, TLS 200
openclaw-sandbox-common:trixie-slim --no-cache after pulling node:22-trixie-slim and golang:1.27-trixie sha256:b0f48d6f2d8c5e14bd006076ec2461b048e14f0e966b6f738800b72c2a19e50c npm 12.2.1, node v22.23.4, go1.27.3, TLS 200

Image rebuilds finished at 2026-10-22T11:45:32Z. This PR is not merged.

Open in Web Open in Cursor 

@cursor cursor Bot changed the title Security: pin patched Node, Go, and CA trust stores Security: enforce trust-store floors and upgrade production dependencies Oct 22, 2026
Node 22 images still ship npm 10 with brace-expansion, picomatch, ip-address, pacote, and sigstore below the advisory floors. Install npm 12.2.1 or newer at build time and refuse the image if that tree regresses. Remove oxlint-tsgolint and the TypeScript native preview from runtime images; their newest binaries were built with Go 1.26.0, before the 1.26.10 trust-store floor.
Deleting the package directories left content-addressed tsgolint and tsgo copies in the pnpm store, so image scans still reported Go 1.26.0. Remove the nested binaries and prune the store after install.
@cursor

cursor Bot commented Oct 22, 2026

Copy link
Copy Markdown

Advisory baseline coverage

Baseline: 22 Oct 2026. Floors are minimums (>= / release-line floors), checked at build time by scripts/check-advisory-floors.mjs and the scripts/docker/ensure-*.sh scripts. node scripts/check-advisory-floors.mjs reports advisory floors satisfied.

component before after floor status
Node engines >=22.12.0 >=22.23.4 <23 || >=24.22.1 <25 || >=26.12.1 22.23.4 / 24.22.1 / 26.12.1 met
pnpm 10.23.0 10.34.7 >=10.34.5 met
npm inside Node images npm 10 (brace-expansion 2.0.2, picomatch 4.0.3, ip-address 10.1.0, pacote 19/20, sigstore 3.1.0) 12.2.1 >=12.2.1 met
Base images bookworm, Node 18/20 in places node:22-trixie, debian:trixie-slim, golang:1.27-trixie, Ubuntu 24.04 install image trixie or Alpine 3.22–3.24; no bookworm met
Go older toolchain go 1.26.10 in scripts/docs-i18n, image golang:1.27-trixie 1.26.10 / 1.27.3 met
pip / certifi distro pip pip>=26.2.2, certifi>=2026.10.19 same met
ca-certificates / OpenSSL (trixie) bookworm OpenSSL, unfixed CVE-2026-84782 20250419+deb13u1 / 3.5.7-1~deb13u3 same met
express 5.2.1 (4.22.1 kept) 5.3.0 (4.22.1 kept) 4.22.1 / >=5.3.0 met
qs 6.14.2 6.16.1 >=6.16.0 met
dompurify 3.3.1 3.4.17 >=3.4.16 met
sanitize-html 2.17.0 2.18.1 >=2.18.1 met
sharp 0.34.5 0.35.5 >=0.35.5 met
undici 7.22.0 8.12.3 and 7.30.1 7.29.1 / >=8.10.2 met
defu 6.1.4 6.1.7 >=6.1.5 met
axios 1.13.5 1.20.0 >=1.20.0 met
vite 7.3.1 8.3.5 7.3.7 / >=8.3.3 met
hono 4.11.9 4.13.13 >=4.13.11 met
postcss 8.5.6 8.5.31 >=8.5.23 met
brace-expansion 2.0.2 / 5.0.2 2.1.7 / 5.0.12 1.1.21 / 2.1.7 / 3.0.9 / 5.0.12 met
tar 7.5.9 7.5.22 >=7.5.21 met
ws 8.19.0 8.22.0 >=8.21.0 met
nanoid 3.3.11 / 5.1.6 3.3.20 / 5.1.16 >=3.3.18 / >=5.1.16 met
ip-address 10.1.0 10.7.4 >=10.3.1 met
picomatch 4.0.3 4.0.7 >=4.0.4 met
simple-git 3.31.1 4.0.2 patched line met
@mariozechner/pi-coding-agent 0.52.12 0.52.12 no patched release kept, unpatched upstream
@buape/carbon unchanged unchanged do not modify kept

Runtime images also drop oxlint-tsgolint and @typescript/native-preview. Their newest releases were compiled with Go 1.26.0, before the 1.26.10 trust-store floor, and no rebuilt binary exists. pnpm store prune removes the content-addressed copies.

Scanners

  • pnpm audit --prod: 0 critical, 1 high. The high is @mariozechner/pi-coding-agent@0.52.12 (GHSA-jfgx-wxx8-mp94). No patched version is published.
  • osv-scanner on the lockfile: 0 critical, 1 high (same advisory), 11 moderate, 4 low.
  • pip-audit on scripts/docker/requirements-pip-certifi.txt and scripts/ci/requirements-detect-secrets.txt: no known vulnerabilities.
  • govulncheck on scripts/docs-i18n: no vulnerabilities.
  • cargo audit: not applicable (no Cargo.toml).
  • composer audit: not applicable (no composer.json).
  • trivy image after --pull --no-cache rebuilds: no fixable high/critical in application dependencies. Remaining highs are:
    • OpenClaw 2026.2.16 (and the matching extension package versions). Trivy maps that version string to later product releases. The package version was not bumped.
    • @mariozechner/pi-coding-agent@0.52.12, no fix.
    • Debian trixie packages with no fixed archive version (linux-libc-dev, MariaDB, OpenEXR, ImageMagick, and similar).
    • pip 26.2.2's vendored BOM (setuptools 70.3.0, urllib3 2.7.0, msgpack 1.1.2). Those copies ship inside the required pip release and are not separate installs.
    • Homebrew portable Ruby's default json gem 2.18.0 in openclaw-sandbox-common. That binary is Homebrew's vendor tree.

Tests and smoke

  • Extension suite: 109 files, 1093 tests passed.
  • Gateway suite: 46 files, 435 tests passed.
  • Unit suite: 5325 tests passed. Six files aborted with SIGABRT under memory pressure and passed on a one-worker rerun (23 tests).
  • Floor-script and Dockerfile tests passed.
  • Cleanup-smoke entrypoint (pnpm build plus reset/uninstall) passed after the store prune.
  • Outbound TLS to https://example.com returned 200, and npm -v was 12.2.1, on openclaw:floor, openclaw-e2e:floor, openclaw-e2e-qr:floor, openclaw-cleanup-smoke:floor, openclaw-install-smoke:floor, openclaw-install-e2e:floor, and openclaw-sandbox-common:trixie-slim. openclaw-sandbox:trixie-slim, openclaw-sandbox-browser:trixie-slim, and openclaw-install-nonroot:floor also returned TLS 200.
  • CI on 122ee8747: Workflow Sanity and Sandbox Common Smoke succeeded.

Not merged.

@battman21
battman21 marked this pull request as ready for review October 22, 2026 11:22
@cursor

cursor Bot commented Oct 22, 2026

Copy link
Copy Markdown

Advisory baseline coverage

Checked again against /cursor/stores/bot/security_baseline.md, including §10 and §11. node scripts/check-advisory-floors.mjs reports advisory floors satisfied. CI on 5765dc974 is green (sandbox-common-smoke, no-tabs).

§10 HTTP/3 QPACK

No HTTP/3 server is shipped.

  • go list modules: scripts/docs-i18n/go.mod requires pi-golang, goldmark, golang.org/x/net, and yaml.v3. There is no quic-go, quiche, lsquic, quinn, h3, or aioquic dependency.
  • No Caddy, Traefik, or cloudflared embed, and no serve({ h3 }) / http3 option.
  • Bun is installed for build scripts only. Bun HTTP/3 stays unpatched upstream, and this repo does not expose a Bun HTTP/3 listener or public UDP/443.

§11 BIND 9 GSS-TSIG

No BIND server is present. Dockerfiles, workflows, install scripts, and docs do not install bind9/named, use tkey-gssapi-keytab / tkey-gssapi-credential, or pull internetsystemsconsortium/bind9 or ubuntu/bind9. Client packages bind9-dnsutils and bind9-libs are not installed. unbound, dnsmasq, CoreDNS, and systemd-resolved are out of scope for CVE-2026-94300.

Exact pins

Image tags float (node:22-trixie, node:22-trixie-slim, debian:trixie-slim, golang:1.27-trixie, ubuntu:24.04). Dockerfiles contain no sha256: digests. Security overrides use minimum floors (>=), not exact versions.

Two exact versions remain because the toolchain requires them:

  • packageManager is pnpm@10.34.7 (Corepack needs an exact version). scripts/docker/ensure-pnpm-floor.sh still rejects anything below 10.34.5 / 11.11.0 / 12.0.0-alpha.5.
  • simple-git is 4.0.2 because pnpm.patchedDependencies must name an exact version. @sinclair/typebox stays at the pre-existing 0.34.48.

setup-node / setup-python

check-latest: true is set on every actions/setup-node@v4 and actions/setup-python@v5 step:

  • .github/actions/setup-node-env/action.yml
  • .github/workflows/ci.yml (Node 22.x and Python 3.12)
  • .github/workflows/install-smoke.yml

Node jobs still run scripts/docker/ensure-node-floor.sh. The Python secrets job still upgrades pip and certifi and runs scripts/docker/ensure-pip-certifi.sh.

Floors (before → after)

component before after floor status
Node >=22.12.0 22.23.4 / 24.22.1 / 26.12.1 those lines met
pnpm 10.23.0 10.34.7 >=10.34.5 met
npm in images 10.x bundled 12.2.1 >=12.2.1 met
Base images bookworm trixie; Ubuntu 24.04 install image trixie or Alpine 3.22–3.24 met
Go older toolchain 1.26.10 / golang:1.27-trixie 1.26.10 / 1.27.3 met
pip / certifi distro >=26.2.2 / >=2026.10.19 same met
express 5.2.1 5.3.0 >=5.3.0 met
qs 6.14.2 6.16.1 >=6.16.0 met
dompurify 3.3.1 3.4.17 >=3.4.16 met
sanitize-html 2.17.0 2.18.1 >=2.18.1 met
sharp 0.34.5 0.35.5 >=0.35.5 met
undici 7.22.0 8.12.3 and 7.30.1 7.29.1 / >=8.10.2 met
axios 1.13.5 1.20.0 >=1.20.0 met
vite 7.3.1 8.3.5 >=8.3.3 met
brace-expansion 2.0.2 / 5.0.2 2.1.7 / 5.0.12 2.1.7 / 5.0.12 met
pi-coding-agent 0.52.12 0.52.12 no patched release kept

Scanners: pnpm audit --prod and osv-scanner are 0 critical and 1 high (@mariozechner/pi-coding-agent@0.52.12, no fix). pip-audit and govulncheck are clean. cargo audit and composer audit do not apply. Rebuilt image Trivy scans have no fixable high/critical application dependencies. Remaining highs are the OpenClaw 2026.2.16 version string (not bumped), the unfixed pi-coding-agent advisory, Debian packages with no archive fix, pip 26.2.2's vendored BOM, and Homebrew portable Ruby's json gem.

Not merged.

@cursor

cursor Bot commented Oct 22, 2026

Copy link
Copy Markdown

Verification on 5765dc9

Local proof on 5765dc974b5d8476063a42617d9a4d3011031923. Host Node v22.23.4, pnpm 10.34.7. GitHub checks on this fork for that SHA are Workflow Sanity (no-tabs) and Sandbox Common Smoke. The full ci.yml suite does not complete here, so the numbers below are from this local run. Nothing is still in progress.

Full test suite

Command: OPENCLAW_TEST_VM_FORKS=0 OPENCLAW_TEST_PROFILE=low node scripts/test-parallel.mjs

Exit 0.

group config result
unit vitest.unit.config.ts, maxWorkers 2 674 files, 5665 tests passed
extensions vitest.extensions.config.ts, maxWorkers 1 109 files, 1093 tests passed, 1 skipped
gateway vitest.gateway.config.ts, pool forks, maxWorkers 1 46 files, 435 tests passed
total 829 files, 7193 passed, 1 skipped

Image rebuilds and smoke tests

Remote-base images: sudo docker build --pull --no-cache. Smoke is an outbound fetch of https://example.com (HTTP 200). Finished 2026-10-22T11:45:32Z.

image build id smoke
openclaw-sandbox:trixie-slim --pull --no-cache sha256:50fbbfebc66ed1dbeae5d9287262b0d6e5c75d85b95f937e8c841f9c4ba9c17e curl as sandbox, TLS 200
openclaw-sandbox-browser:trixie-slim --pull --no-cache sha256:e8e869e7762f283eae022ee4e33a00fd181941c159645117dadcfc327f7b2f2e curl TLS 200; node v22.23.4 fetch TLS 200. npm is not in this image (only the Node binary is copied)
openclaw-install-nonroot:floor --pull --no-cache sha256:a97a54f6c94aaab183c3ee35b49314580e7e35e763e7d0f276b9782fb17c62dc curl as app, TLS 200
openclaw-install-smoke:floor --pull --no-cache sha256:85b62d6447b462d19f5435a54db0b25f9c49545d9e9f3f7087f8e1431d7eed8b npm 12.2.1, TLS 200
openclaw-install-e2e:floor --pull --no-cache sha256:e9b15d8283557d3db27680f48c26465f309a721d5c45e5d3a3557439479b1e6d npm 12.2.1, TLS 200
openclaw-cleanup-smoke:floor --pull --no-cache sha256:9506efe711309c88707046f7bbf0fe173d6e6766b77e1ea1775c47c76b5d14b2 npm 12.2.1, TLS 200. Entrypoint (pnpm build, reset, uninstall) printed OK
openclaw-e2e:floor --pull --no-cache sha256:9ef700f0eb326c4c88a387a67e5328fa35bbe719f1ce67ed207275345051a019 node v22.23.4, npm 12.2.1, TLS 200
openclaw-e2e-qr:floor --pull --no-cache sha256:80d7ad1021e79251bf1af3244c788ff33c155f56584dd887c45122894893fc18 npm 12.2.1, TLS 200
openclaw:floor --pull --no-cache sha256:7011f46939b82dacd69b08a9e41b19fe9adf7206c9b1524faf6cba3233c42aef node v22.23.4, npm 12.2.1, TLS 200
openclaw-sandbox-common:trixie-slim --no-cache after docker pull node:22-trixie-slim and docker pull golang:1.27-trixie sha256:b0f48d6f2d8c5e14bd006076ec2461b048e14f0e966b6f738800b72c2a19e50c node v22.23.4, npm 12.2.1, go1.27.3, TLS 200

openclaw-sandbox-common is built FROM the local tag openclaw-sandbox:trixie-slim. docker build --pull would try to pull that tag from a registry, so that image used --no-cache after the remote Node and Go stages were pulled.

Not merged.

@battman21
battman21 merged commit 88d0fa1 into main Oct 22, 2026
2 checks passed
@battman21
battman21 deleted the cursor/security-trust-store-node-564b branch October 23, 2026 22:52
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.

2 participants