Repository navigation
Distrust the compromised eMudhra certificates - #127318
Conversation
The private keys of eight eMudhra intermediate CAs issued in 2025 can be recovered from their certificates. Reject any certificate chain that contains one of them, or one of the roots that issued or cross-signed them (`emSign Root TLS CA - G3`, `emSign Root CS CA - G3`, `emSign ECC Root CA - G3`), regardless of the trust store it was built from, including the trust store of the operating system. The keys are identified by the SHA-256 of their `SubjectPublicKeyInfo`, so the cross-signed certificates of the same keys (issued by Sectigo `AAA Certificate Services`) are rejected as well. The check is done in `Poco::Net::SSLManager::verifyCallback`. Also update the CA certificates embedded into the binary (`contrib/grpc/etc/roots.pem`) from the Chromium root store, which removes `emSign ECC Root CA - G3`. Related: https://emudhra.we-have-a-problem.com/ Related: ClickHouse/grpc#46 Related: grpc/grpc#43699 Co-Authored-By: Claude Opus 5.5 <[email protected]>
|
Workflow [PR], commit [a815ff7] Summary: ✅
AI ReviewSummaryThe PR adds public-key distrust checks for the compromised eMudhra CAs and refreshes the embedded CA bundle. One previously reported coverage gap remains: outbound Keeper connections bypass the check even with certificate verification enabled. The author explicitly deferred that work; no new inline findings were identified. Findings
Tests
Missing context / blind spots
Final VerdictStatus: |
Build profile diff (arm_release)Commit See the job log for details. |
The updated root store embeds 99 certificates, so lower the threshold in `test_embedded_ca_certificates` from 100 to 50. Co-Authored-By: Claude Opus 5.5 <[email protected]>
|
Updated the submodule after merging the PR and fixed the test (it was expecting to have a large number of certificates). I've also added the tag to backport because although it's technically a breaking change I think its benefits far outweigh the possible risks and incompatibilities. |
Backport #127318 to 26.10: Distrust the compromised eMudhra certificates
Cherry pick #127318 to 26.3: Distrust the compromised eMudhra certificates
Removed the integration test for the embedded CA certificates, which stable-25.8 doesn't have; the distrust check and grpc bump applied cleanly.
Dropped the integration test for the embedded CA certificate fallback, which antalya-25.8 doesn't have; the Poco distrust check, gtest and grpc bump applied cleanly.
Dropped the integration test change because stable-26.3 doesn't have `test_embedded_ca_certificates` or the embedded CA fallback; the rest of the PR applied unchanged.
Dropped the threshold change to test_embedded_ca_certificates/test.py, which doesn't exist on antalya-26.3; the rest of the PR applied cleanly.
Removed the modify/delete-conflicted integration test, which doesn't exist on antalya-26.6; the rest of the PR (distrust check, gtest, grpc CA bundle bump) applied without conflicts.
Dropped the integration test change because stable-26.8 has neither the test nor the embedded-CA fallback it tests; everything else applied cleanly.
Deleted the integration test for the built-in CA certificates fallback, which antalya-26.8 doesn't have; the distrust check, its unit test and the grpc update are kept as in the source PR.
Antalya 25.8 Backport of ClickHouse#127318 - Distrust the compromised eMudhra certificates
Antalya 26.3 Backport of ClickHouse#127318 - Distrust the compromised eMudhra certificates
Stable 25.8 Backport of ClickHouse#127318 - Distrust the compromised eMudhra certificates
Stable 26.8 Backport of ClickHouse#127318 - Distrust the compromised eMudhra certificates
Stable 26.3 Backport of ClickHouse#127318 - Distrust the compromised eMudhra certificates
Antalya 26.6 Backport of ClickHouse#127318 - Distrust the compromised eMudhra certificates
Antalya 26.8 Backport of ClickHouse#127318 - Distrust the compromised eMudhra certificates
Stable 25.3 Backport of ClickHouse#127318 - Distrust the compromised eMudhra certificates
Stable 24.8 Backport of ClickHouse#127318 - Distrust the compromised eMudhra certificates
Stable 24.3 Backport of ClickHouse#127318 - Distrust the compromised eMudhra certificates
Stable 23.8 Backport of ClickHouse#127318 - Distrust the compromised eMudhra certificates
FIPS 25.3 Backport of ClickHouse#127318 - Distrust the compromised eMudhra certificates
Hardening in response to the eMudhra incident: the private keys of eight eMudhra intermediate CAs, issued in 2025, can be recovered from their certificates.
There is no security issue for ClickHouse in typical use cases, and this PR is merely hardening. The affected intermediates have never been logged to Certificate Transparency and are already revoked; browsers and operating system vendors (Chrome, Firefox, Apple, Microsoft) have already blocked them, and ClickHouse uses the trust store of the operating system by default.
The PR does two things:
Distrust the compromised certificates regardless of the trust store. Any certificate chain that contains one of the eight intermediates, or one of the roots that issued or cross-signed them (
emSign Root TLS CA - G3,emSign Root CS CA - G3,emSign ECC Root CA - G3), is rejected withcertificate revoked, even if the trust store of the operating system (or a configuredcaConfig) still contains them, e.g. on a system that has not been updated. Keys are matched by the SHA-256 of theSubjectPublicKeyInfo, the same way as Chrome's CRLSet, so the certificates of the same keys cross-signed by SectigoAAA Certificate Servicesare rejected as well. The check is done inPoco::Net::SSLManager::verifyCallback, so it applies to all TLS connections made through Poco (HTTP/S3/URL clients, the native protocol, interserver communication, Keeper, client certificates on the server side). Libraries that create their own OpenSSL contexts (e.g.librdkafka,libpq) are not covered.emSign Root CA - G1is unaffected and stays trusted, as in Chrome, Mozilla, gRPC and certifi. All fingerprints were checked against the certificates published at https://emudhra.we-have-a-problem.com/.Update the bundle of CA certificates embedded into the binary (
contrib/grpc/etc/roots.pem) from the Chromium root store, following upstream gRPC. This removesemSign ECC Root CA - G3, along with the other recent Chromium root store changes. Note that this bundle is not used in typical scenarios: it is only a fallback for when no CA certificates can be found on the filesystem, e.g. in a container built "from scratch".Related: https://emudhra.we-have-a-problem.com/
Related: ClickHouse/grpc#46
Related: grpc/grpc#43699
Related: certifi/python-certifi#440
Changelog category (leave one):
Changelog entry (a user-readable short description of the changes that goes into CHANGELOG.md):
Hardening: certificate chains containing the compromised eMudhra intermediate CAs or the roots that issued them (
emSign Root TLS CA - G3,emSign ECC Root CA - G3) are rejected even if the trust store of the operating system still trusts them. The CA certificates embedded into the binary (used only when the system has none) are updated from the Chromium root store. There is no security issue in typical use cases.🤖 Generated with Claude Code
Workflow [PR]
Sync PR [sync-upstream/pr/127318]
Version info
26.11.1.646-master(included in26.11and later)26.10.2.96,26.9.26.9,26.8.35.8,26.7.38.16,26.3.61.3