Skip to content

fix(images): pin the current Debian security releases in image builds - #86

Merged
derekhsu merged 3 commits into
feat/image-only-clifrom
issue/85-debian-pin-drift
Nov 24, 2026
Merged

derekhsu merged 3 commits into
feat/image-only-clifrom
issue/85-debian-pin-drift

Conversation

@derekhsu

@derekhsu derekhsu commented Nov 24, 2026 •

Copy link
Copy Markdown
Owner

Summary

Debian removed several package versions that the image builds pin, so the base and tools image builds fail without the Docker cache. This is why Hermes Tools Verify, OpenClaw Tools Verify, and PR build and direct managed startup fail on #84. This change pins the versions that the trixie archive has now and keeps the tools images on the libc6 of their published base images.

Related Issue

Closes #85

Changes

  • The four Dockerfile.base files (Dockerfile.base, agents/hermes-01x/, agents/hermes/, agents/langchain-deepagents-code/) now pin:

    • ca-certificates=20250419+deb13u1
    • zlib1g-dev=1:1.3.dfsg+really1.3.1-1+deb13u1
    • xz-utils=5.8.1-1+deb13u2, in the two files that still pinned deb13u1
    • libc6 and libc-bin 2.41-12+deb13u5

    dos2unix already uses 7.5.2-1*, which matches the current 7.5.2-1+b1.

  • The security package inventory (src/lib/sandbox-base-image/security-package-specs.ts and its copy, scripts/security/standalone-security-package-inventory.mts) now expects glibc deb13u5. The inventory for the digest-pinned Hermes sandbox base (hermes-compatible) keeps deb13u4, the same way it keeps the older Python htmlparser fix. That base predates the update.

  • Dockerfile.tools and agents/hermes-01x/Dockerfile.tools: the perl-modules stage needs libc6-dev at exactly the base image's libc6 version. The published base images hold libc6 2.41-12+deb13u4, but the archive now has only deb13u5. The stage now installs libc6-dev and libc-dev-bin 2.41-12+deb13u4 from snapshot.debian.org. The downloads are pinned by SHA-256, and the SHA-1 of each file matches the snapshot record. Only this build stage uses them; the final image does not include them. The published base images do not change.

  • tools/openclaw-tools-image/apt-packages-browser.txt pins chromium and chromium-common at 156.0.8078.108-1~deb13u1. trixie-security replaced 156.0.8078.79, and the tools Trivy gate reported HIGH findings in it. With chromium pinned to the older release, apt 3.0 did not select the older chromium-common on its own, so both are pinned. The fixture's version check follows.

  • Not fixed here: PR build and direct managed startup (Deep Agents Code) fails. Its PR build uses a pinned upstream base with glibc deb13u4, which no longer matches the inventory, and the fork's agents/langchain-deepagents-code/Dockerfile.base cannot build because four files it copies are missing. fix(images): Deep Agents Code 的固定 base 不符 glibc deb13u5 受控套件清單 #87 tracks it.

  • Dockerfile.base: HOMEBREW_VERSION=7.0.16. Changing Dockerfile.base runs OpenClaw Standard Verify, which reported CVE-2026-126366 (HIGH) in msgpack 1.8.5 from Homebrew 7.0.12's portable Ruby 4.0.9. Homebrew 7.0.16 ships portable Ruby 4.0.10 with msgpack 1.8.7 and json 3.1.0 (both bottles checked against Homebrew's SHA-256 pins). The CVE-2026-33210 entry in ci/trivy-standard-image-exceptions.json no longer matches a finding, and the gate fails on unused entries, so it is removed.

  • Tests: the expected inventory, the dpkg-query mocks, and the published-Hermes-base case are updated.

  • Docs: docs/modification/2026-10-31-openclaw-tools-image.md (§3.1, §3.2, §6.3) and docs/security/openclaw-2026.9.2-dependency-review.md (Homebrew 7.0.16).

Type of Change

  • Code change (feature, bug fix, or refactor)
  • Code change with doc updates
  • Doc only (prose changes, no code sample modifications)
  • Doc only (includes code sample changes)

Quality Gates

  • Tests added or updated for changed behavior
  • Existing tests cover changed behavior — justification:
  • Tests not applicable — justification:
  • Docs updated for user-facing behavior changes
  • Docs not applicable — justification:
  • Sensitive paths changed (security, policy, credentials, preflight, onboarding, inference, runner, sandbox, or messaging)
  • Sensitive-path review completed or maintainer-approved waiver recorded — reviewer/approval link/justification: the change updates the security package inventory to Debian's glibc security release and keeps the older inventory only for the digest-pinned Hermes base. The tools image downloads are pinned by SHA-256 and do not reach the final image. Awaiting maintainer review.
  • Non-success, skipped, or missing CI check accepted by maintainer — check name, approval link, and follow-up issue: PR build and direct managed startup (Deep Agents Code), follow-up fix(images): Deep Agents Code 的固定 base 不符 glibc deb13u5 受控套件清單 #87; awaiting maintainer acceptance.

Documentation Writer Review

  • Documentation writer subagent reviewed the completed changes
  • Result: docs-updated
  • Evidence: docs/modification/2026-10-31-openclaw-tools-image.md, docs/security/openclaw-2026.9.2-dependency-review.md. Two reviews ran, one per commit. The second found stale present-tense text about the removed exception and a date style; both were applied. The first review found one accuracy issue in §6.3: the text called the base image's libc6 deb13u4, but the Dockerfile.base files now pin deb13u5. I applied the suggested wording before the commit. It found no other doc that needs changes; older docs/security/ mentions of deb13u4 are dated reviews. npm run docs does not apply: docs/modification/ is not part of the Fern site.
  • Agent: Claude Code

DGX Station Hardware Evidence

  • Tested on DGX Station
  • Tested commit:
  • Station profile/scenario:
  • Result:
  • Supporting evidence:

Verification

  • PR description includes a Signed-off-by: line and every commit appears as Verified in GitHub
  • Normal pre-commit, commit-msg, and pre-push hooks passed, or npm run validate:pr passed after refreshing origin/main when hooks were skipped or unavailable
  • Targeted behavior tests pass for the current change set, or tests are marked not applicable above — command/result or justification: npx vitest run test/runtime/sandbox/sandbox-base-security-packages.test.ts 119 passed. The 64 test files that read the Dockerfiles or the inventory: 1285 passed and 5 failed when run together. Run alone, those 3 files pass (59 tests); with the same tests, the base branch fails 2 in src/commands/image/stage.test.ts. hadolint passes on all six changed Dockerfiles.
  • Applicable broad gate passed — npm test for broad runtime/test-harness changes; npm run check for repo-wide validation/coverage changes — command/result:
  • Quality Gates section completed with required justifications or waivers
  • No secrets, API keys, or credentials committed
  • npm run docs builds without warnings (doc changes only)
  • Doc pages follow the style guide (doc changes only)
  • New doc pages include SPDX header and frontmatter (new pages only)

Not verified locally: no image was built for this change. The local Docker storage has a damaged btrfs block, so the user chose to let CI verify the builds. On the first CI run, the Hermes and OpenClaw base builds passed and all four tools images built, including the libc6-dev snapshot step on both OpenClaw bases. The follow-up commit addresses the remaining failures above. cli-test-shards (6) timed out in host-local-vllm-selection.test.ts, as on #84, and reviewed-npm-audit hit an npm registry fetch error; neither relates to this change.


Signed-off-by: Derek Hsu derekhsu@hotmail.com

🤖 Generated with Claude Code

derekhsu and others added 2 commits November 24, 2026 15:24
Debian removed several pinned package versions from the trixie archive,
so the base and tools image builds fail without the Docker cache.

- Base images: pin ca-certificates 20250419+deb13u1, zlib1g-dev
  +deb13u1, xz-utils 5.8.1-1+deb13u2, and glibc 2.41-12+deb13u5.
- Security package inventory: expect glibc deb13u5. The inventory for the
  digest-pinned Hermes sandbox base keeps deb13u4.
- Tools images: the perl-modules stage installs libc6-dev and
  libc-dev-bin 2.41-12+deb13u4 from snapshot.debian.org, matching the
  libc6 in the published base images.
- Tools images: pin chromium-common, which apt 3.0 no longer selects
  for chromium while the controlled packages are held.

Closes #85

Signed-off-by: Derek Hsu <derekhsu@hotmail.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
CI on #86 showed three more failures once the images built again.

- Deep Agents Code: build the PR base from its Dockerfile.base. The
  pinned upstream base predates glibc 2.41-12+deb13u5.
- Tools images: pin chromium and chromium-common at the trixie-security
  release 156.0.8078.108-1~deb13u1, which fixes the HIGH findings in
  156.0.8078.79.
- OpenClaw Standard: move Homebrew to 7.0.16. Its portable Ruby 4.0.10
  carries msgpack 1.8.7 (CVE-2026-126366) and json 3.1.0, so the
  CVE-2026-33210 exception no longer matches a finding and is removed.

Refs #85

Signed-off-by: Derek Hsu <derekhsu@hotmail.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The fork's agents/langchain-deepagents-code/Dockerfile.base copies four
files that the fork does not have, so the PR build cannot build its base
from it. Restore the pinned upstream base. Its glibc deb13u4 no longer
matches the security inventory; #87 tracks that check.

Refs #85

Signed-off-by: Derek Hsu <derekhsu@hotmail.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@derekhsu
derekhsu merged commit f5620ef into feat/image-only-cli Nov 24, 2026
60 of 65 checks passed
derekhsu added a commit that referenced this pull request Nov 24, 2026
Bring in #86 so the image checks build on the current Debian pins.

Signed-off-by: Derek Hsu <derekhsu@hotmail.com>
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.

fix(images): Debian 套件庫更新後,base 與 tools 映像的版本鎖定無法安裝

1 participant