Repository navigation
Conversation
2 tasks
The private keys of eight eMudhra (emSign) intermediate CA certificates were disclosed on 2026-10-20, so anyone can issue a certificate that software trusting emSign ECC Root CA - G3 accepts (https://emudhra.we-have-a-problem.com). - uv.lock: certifi 2026.5.20 -> 2026.10.19, the first certifi release without that root. Nothing else in the lock moves. - worker_identity: re-pin APPROVED_UV_LOCK_SHA256 for the new lock. - Modal stage image: uv 0.11.7 -> 0.13.4 (uv verifies HTTPS against a CA list compiled into it), a certifi 2026.10.19 floor beside the runner's huggingface_hub, and ca-certificates named in apt_install so the image upgrades Debian's system CA store. - Runbook and changelog fragment. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
anth-volk
force-pushed
the
emudhra-ca-trust-update
branch
from
October 22, 2026 17:53
36fab6f to
4677653
Compare
This branch has not been deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Fixes #1351
The incident
On 2026-10-20 it was disclosed that the private keys of eight eMudhra (emSign) intermediate CA certificates were generated so weakly that anyone can recover them from the public certificates (https://emudhra.we-have-a-problem.com). Anyone holding a key can issue a certificate for any domain, so a client that trusts
emSign ECC Root CA - G3(or Sectigo's cross-signature of the same intermediates) can have its HTTPS traffic intercepted. Browsers are protected; software that carries its own CA list, or reads a system CA store that has not been updated, is not.What in this repository trusted the affected roots
uv.lockpinned certifi 2026.5.20, which still containsemSign ECC Root CA - G3. requests 2.34.2 and httpx 0.28.1 (used by huggingface_hub 1.18.0) verify against certifi, and the build tools use them to download Census, Hugging Face and other sources. Measured: requests with certifi 2026.5.20 got HTTP 200 from https://dv-g3b-emudhra.we-have-a-problem.com/; with certifi 2026.10.19 it raisedCERTIFICATE_VERIFY_FAILED.tools/modal_us_stage.py) installed uv 0.11.7. uv verifies HTTPS against a CA list compiled into it, and the image'suv sync --frozendownloads every locked wheel with it. Measured: uv 0.11.7 completed the TLS handshake with the test endpoint above (the server's plain-text response reached uv's index parser); uv 0.13.4 refused it withinvalid peer certificate: UnknownIssuer. The lock's hashes still protected the wheel contents; the connection itself did not.huggingface_hub==1.18.0. Modal reuses a cached layer while its definition is unchanged, so the runner kept whichever certifi PyPI served when that layer was first built. The runner downloadshf://inputs with it, sendingHF_TOKENwhen an input lives in a private or access-restricted Hub repository.ca-certificatespackage. git's fetch from GitHub and the stdlibsslmodule (urllib) verify against that system store. Measured indebian:bookworm-slim: with ca-certificates 20230311+deb12u1, curl got HTTP 200 from both test endpoints; afterapt-get install ca-certificates(which upgraded it to 20250419~deb12u2 from bookworm-security), curl refused both withunable to get local issuer certificate.debian:trixie-slimupgrades to 20250419+deb13u1. In both,emSign ECC Root CA - G3is gone from/usr/share/ca-certificates/mozilla.Checked and left unchanged:
verify=False,SSL_CERT_FILE,REQUESTS_CA_BUNDLE,NODE_EXTRA_CA_CERTS,GRPC_DEFAULT_SSL_ROOTS_FILE_PATH,CERT_NONEand similar).astral-sh/setup-uv@v6has no version input and the repository declares norequired-version, so it installs the newest uv; main's lint job on 2026-10-21 installed uv 0.13.4.actions/setup-nodeasks for the range"24", not an exact release, and runs only the Orrery parser contract test. The runners' system CA store is maintained by GitHub.docs/evidence/us-release-reimputation-1191/scripts/platform/Dockerfile(uv 0.9.26,python:3.14.2-slim-bookworm) is the committed record of a past offline replay. Its requirements are hash-pinned, nothing deploys it, and changing it would stop it matching the measurement it records.experiments/us-acs-local-l2-basis-20260928/modal_sweep.pyis a dated experiment whose containers make no HTTPS requests of their own.Changes
uv.lock: certifi 2026.5.20 -> 2026.10.19. Nothing else in the lock moves.microcosm.build.us_runtime.worker_identity:APPROVED_UV_LOCK_SHA256re-pinned to the new lock's digest (60ba4a85…), as every lock change requires.tools/modal_us_stage_plan.py:IMAGE_UV_VERSION0.11.7 -> 0.13.4, and a newRUNNER_CERTIFI_MINIMUM_VERSION = "2026.10.19".tools/modal_us_stage.py: the image'sapt_installalso namesca-certificates, so the build upgrades it to Debian's current release; the runner'spip_installaddscertifi>=2026.10.19.docs/us-modal-stage-runbook.md: the image description follows.changelog.d/emudhra-ca-trust.fixed.md.Checks
uvx uv@0.13.4 lock --check(the uv CI installs): passes. I generated the lock with uv 0.12.23 (uv lock --upgrade-package certifi), which changes only the certifi entry. uv 0.13.4's re-resolution writes the same certifi entry but also rewrites 49 dependency markers and drops the Windows wheels of the CUDA packages; uv 0.13.4 accepts the certifi-only lock as current, so I kept the smaller diff.uvx uv@0.13.4 sync --all-packages --locked: succeeds and installs certifi 2026.10.19, whose bundle contains neitheremSign ECC Root CA - G3norAAA Certificate Services.ruff checkandruff format --check(ruff 0.15.16 from the lock) on the three changed Python files: pass.python3 tools/ci_test_plan.py verify: ok.pytest -n 4 --dist loadfileontest_us_stacked_spine.py,test_us_multispine_pool_h5_io.py,test_us_spine_blindness.py(the tests that useAPPROVED_UV_LOCK_SHA256) and the threetest_us_modal_stage_*modules: 1337 passed, 6 skipped.modalwith a stub, so they do not exercise the image definition.Operator actions after merge
modal run tools/modal_us_stage.pyfrom a checkout that includes this change rebuilds the base layers; no forced rebuild is needed. The runner code comes from the operator's checkout, but/opt/venvis synced from the plan commit's ownuv.lock, so a plan pinned to a commit before this merge still installs certifi 2026.5.20 for the stage tool. Point new plans at a commit that includes this change.ca-certificatesis 20250419~deb12u2 (bookworm) or 20250419+deb13u1 (trixie). I could not check which Debian release and apt sources Modal'sdebian_slimuses for this workspace.tools/route_a/route_a.sh): runuv syncat a commit that includes this change.Environment-variable verification
This PR changes the Modal image definition, so here is every environment variable that code reads or declares:
UV_PROJECT_ENVIRONMENT,UV_PYTHON_DOWNLOADS,UV_LINK_MODE,PYTHONDONTWRITEBYTECODE.env({...})(unchanged here).envto the laterrun_commandsbuild steps (uv sync) and to the running containerMICROCOSM_MODAL_PLANmodal.is_local())MICROCOSM_MODAL_HF_SECRETmodal.Secret.from_nameonly when setHF_TOKENhuggingface_hubGIT_TERMINAL_PROMPT"0"in the runnerPer-plan tool variables come from the plan file (
plan.env) and are not changed by this PR. The CI workflow is not changed.🤖 Generated with Claude Code