Repository navigation
fix(docker): drop CA roots behind the compromised eMudhra intermediates - #128
David Larsen (dc-larsen) wants to merge 4 commits into
Conversation
|
Pushed fe2451d on top of this branch to close the three gaps listed under "Not in this PR":
CHANGELOG entry updated to match. Rebuilt both images locally (
api.socket.dev, registry.npmjs.org, github.com and Trivy's real DB download still connect. Release and the Python CLI 2.11.2 bump for heavy (SocketDev/socket-python-cli#415) are staged separately. |
The private keys for eight eMudhra intermediate CAs leaked (disclosed 2026-10-20). Every TLS client in the 3.4.0 image still trusts certificates issued from them. Require ca-certificates 20250419+deb13u1 or newer. It removes emSign ECC Root CA - G3 and AAA Certificate Services, the two roots those intermediates chain to. The bundled Trivy and TruffleHog read the system store, so they reject the chains even on their current Go toolchains. Bump certifi to 2026.10.19, which drops the same emSign root for the requests calls to our API and GitHub.
Apply the ca-certificates floor to Dockerfile.heavy, floor certifi on the heavy image's system interpreter (which runs the Python CLI outside the locked venv), and set NODE_OPTIONS=--use-openssl-ca in both images so Node and the Socket npm CLI use the patched system store until Node ships its fix.
fe2451d to
8e82296
Compare
|
bugbot run |
There was a problem hiding this comment.
✅ Bugbot reviewed your changes and found no new issues!
Comment @cursor review or bugbot run to trigger another review on this PR
Reviewed by Cursor Bugbot for commit 8e82296. Configure here.
…tem store Node 22.23.4 rejects the compromised eMudhra intermediates itself, and NodeSource's setup_22.x already serves it. Fail the build on an older Node and drop NODE_OPTIONS=--use-openssl-ca, which a caller's own NODE_OPTIONS would have overridden.
Summary
Updates the standard and heavy images so their TLS clients stop trusting the eMudhra intermediate CAs whose keys were disclosed on 2026-10-20 (details). In 3.4.0, curl, Python
requests, Node, Trivy (go1.26.3) and TruffleHog (go1.25.12) all accept them.Changes
Dockerfile,Dockerfile.heavy: fail the build unlessca-certificatesis20250419+deb13u1or newer. That release drops the two roots the compromised intermediates chain to. Trivy and TruffleHog read the system store, so this covers them on their current Go toolchains. Changing theRUNline also avoids reusing a cached apt layer with the old bundle.Dockerfile,Dockerfile.heavy: fail the build below Node 22.23.4, which rejects the compromised intermediates itself (NodeSource'ssetup_22.xalready serves it). An earlier revision setNODE_OPTIONS=--use-openssl-cainstead; that's gone, so a caller's ownNODE_OPTIONSno longer matters.Dockerfile.heavy:certifi>=2026.10.19for the system interpreter, which runs the Python CLI outside the locked venv.CHANGELOG.md: entry under[Unreleased].The certifi bump in
uv.lock(2026.10.19) landed separately in #129.Not in this PR:
trivyandtrufflehoguntil they're rebuilt on Go 1.26.10+ or 1.27.3+. Trivy needs a trivy-dist rebuild, and TruffleHog's latest release (3.99.3) is still on go1.27.2.action.ymlpins3.4.0, so action users get this in the next release (chore(release): 3.4.1 #130).Testing
Built both images locally, with
TRIVY_IMAGEpointed at the published 3.4.0 image (the Socket-built Trivy base needs registry access). Then ran each client against the disclosure site's test hosts,dv-g3b-emudhra.we-have-a-problem.comanddv-g3b-aaa-emudhra.we-have-a-problem.com:requests(venv and system interpreter)fetchapi.socket.dev, api.github.com, ghcr.io, pypi.org, the npm registry and Trivy's real DB download still connect.
smoke-test-docker.shpasses for themainandheavycheck sets.scripts/integration-test-docker.sh(standard image) anduv lock --lockedpass.To check by hand:
3.4.0 prints 200; this branch fails certificate verification.
Note
High Risk
Changes container-wide TLS trust and Node TLS behavior; misconfiguration could break legitimate HTTPS or leave a gap if version checks fail silently—but the intent is critical security hardening after a CA compromise.
Overview
Hardens TLS trust in the standard and heavy Docker images after the disclosed eMudhra intermediate CA compromise, so bundled clients stop accepting certificates chaining to the affected roots.
Both
DockerfileandDockerfile.heavynow fail the image build unless installedca-certificatesis at least20250419+deb13u1, which drops the roots those intermediates chain to. That patched system store coverscurl,git, Trivy, TruffleHog, and Python in the locked venv.NODE_OPTIONS=--use-openssl-cais set so Node and the Socket npm CLI use that system store instead of Node’s still-vulnerable bundled CAs until upstream ships a fix.The heavy image additionally pins
certifi>=2026.10.19on the system interpreter used by the Python CLI.CHANGELOG.mddocuments the fix and notes scanners may still flag CVE-2026-111943 on the Go binaries until they’re rebuilt on newer Go versions.Reviewed by Cursor Bugbot for commit 8e82296. Configure here.