Skip to content

Distrust the compromised eMudhra intermediate CA keys (#93 on current main) - #96

Merged
quinnj merged 2 commits into
mainfrom
claude/distrust-emudhra
Oct 22, 2026
Merged

quinnj merged 2 commits into
mainfrom
claude/distrust-emudhra

Conversation

@quinnj

@quinnj quinnj commented Oct 22, 2026

Copy link
Copy Markdown
Member

Ian Butterworth's #93 on top of today's main, so it can be merged and released as 1.7.1. #93 conflicts with #87, #94 and #95 only in test/runtests.jl (both sides append testsets at the end); this keeps both.

  • 460d931 is Ian's commit, cherry-picked unchanged (his authorship kept): after a verified connect, the SHA-256 of every verified-chain certificate's SubjectPublicKeyInfo is checked against the eight compromised eMudhra intermediate keys, and a match fails the connection. Bumps the version to 1.7.1.
  • d26daff (new): if the second i2d_X509_PUBKEY call fails, spki_sha256 now throws. Before, it hashed uninitialized bytes, which match no distrusted key, so the check passed.

Review notes:

  • The eight hashes match Reseau 1.6.1's list (Distrust compromised eMudhra CA keys; release 1.6.1 JuliaServices/Reseau.jl#190, which cites Go 1.27.3's crypto/x509 denylist), and the names in the comments match the certificate subjects.
  • Recomputed with the openssl CLI: all 16 fixture intermediates (each key under two issuers) hash to the published spki-sha256.txt values.
  • The fixtures are 19 public certificates and nothing else (no keys), byte-identical to Reseau's.
  • Fails closed: a missing verified chain counts as distrusted, and an encoding failure throws. The check runs only when require_ssl_verification=true, after SSL_get_verify_result is OK. OpenSSL.jl's client never resumes sessions, so the verified chain is always present after a successful verification.

Verification:

  • Full suite on Julia 1.12.6 (macOS): passes, DistrustedKeys 37/37.
  • With has_distrusted_key stubbed to return false, the end-to-end handshake test fails.

Fixes #92

Co-authored-by: Ian Butterworth i.r.butterworth@gmail.com

🤖 Generated with Claude Code

IanButterworth and others added 2 commits October 22, 2026 10:00
The private keys of eight eMudhra intermediate CAs were compromised in
October 2026. On macOS and Windows the default roots come from Julia's
bundled `cert.pem`, which still trusts chains through them and can only be
updated by a Julia release. Removing roots would not be enough anyway,
because the intermediates are also cross-signed under another root.

After a verified `connect`, check the public key of every certificate in
the verified chain against the eight keys, and fail the connection on a
match. This is the same list that Go and Reseau.jl use.

Bump the version to 1.7.1.

Fixes #92

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
If the second i2d_X509_PUBKEY call failed, the hash was taken over
uninitialized bytes, which match no distrusted key, so the check passed.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@quinnj
quinnj merged commit a6511cc into main Oct 22, 2026
12 checks passed
@quinnj
quinnj deleted the claude/distrust-emudhra branch October 22, 2026 16:07
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.

Distrust the compromised eMudhra intermediate CA keys

2 participants