Repository navigation
tls: honour Mozilla distrust-after dates for bundled roots - #67412
Open
UlisesGascon wants to merge 1 commit into
Open
UlisesGascon wants to merge 1 commit into
UlisesGascon wants to merge 1 commit into
Conversation
Mozilla keeps emSign Root CA - G1, Izenpe.com and Firmaprofesional CIF A62634068 in its root store but distrusts TLS server certificates they issued after 2026-11-16, 2026-04-15 and 2026-08-06 respectively (CKA_NSS_SERVER_DISTRUST_AFTER). tools/mk-ca-bundle.pl does not carry that attribute into node_root_certs.h, so Node.js keeps accepting new certificates from these roots that browsers reject. Add a distrust-after table next to the SPKI blocklist in the certificate verify callback. When a client verifies a server chain through a listed key and the leaf's notBefore is after the key's cutoff, the chain fails with CERT_REVOKED; certificates issued up to the cutoff keep working. Client certificates are not affected: the attribute is Mozilla's server authentication policy, the roots stay trusted anchors otherwise, and this matches the scope of the 2016 StartCom/WoSign cutoff. Node.js has no Certificate Transparency checking, so a backdated notBefore is not detected, as with that cutoff. Fixes: nodejs#67391 Refs: https://bugzilla.mozilla.org/show_bug.cgi?id=2089115 Assisted-by: Claude, Codex, Mistral Signed-off-by: Ulises Gascon <ulisesgascongonzalez@gmail.com>
Collaborator
|
Review requested:
|
Contributor
|
The
notable-change
Please suggest a text for the release notes if you'd like to include a more detailed summary, then proceed to update the PR description with the text or a link to the notable change suggested text comment. Otherwise, the commit will be placed in the Other Notable Changes section. |
UlisesGascon
marked this pull request as ready for review
November 11, 2026 14:41
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.
Mozilla keeps emSign Root CA - G1, Izenpe.com and Firmaprofesional CIF A62634068 in its root store but distrusts TLS server certificates they issued after 2026-11-16, 2026-04-15 and 2026-08-06 respectively (
CKA_NSS_SERVER_DISTRUST_AFTER).tools/mk-ca-bundle.pldoes not carry that attribute intonode_root_certs.h, so Node.js keeps accepting new certificates from these roots that browsers reject.This adds a distrust-after table next to the SPKI blocklist from #66871, checked from the same verify callback on every SSL_CTX. When a client verifies a server chain through a listed key and the leaf's
notBeforeis after the cutoff, the chain fails withCERT_REVOKED; certificates issued up to the cutoff keep working. The table is keyed by public key, so a cross-signed copy of the root is caught as well.Client certificates are not affected. The attribute is Mozilla's server authentication policy, the roots stay trusted anchors otherwise, and these CAs are large issuers of personal certificates. This is the scope the 2016 StartCom/WoSign cutoff had (89217d1).
The test uses a fixture CA that is a permanent entry on the list with a 2019 cutoff, with leaves issued exactly at the cutoff and one second after it, so nothing depends on the clock. Its key is pinned in the fixtures Makefile like
blocked-ca-key.pem.Known limitation
Node.js has no Certificate Transparency checking, so a backdated
notBeforeis not detected. Same as the 2016 cutoff.Points for reviewers
crypto_context.ccfor now.A follow-up PR generates them fromOnce tools: generate distrust-after dates from certdata.txt #67414 land that step will be automated.certdata.txton every root certificate update.mk-ca-bundle.pl. The two are complementary: that one removes a root outright, this one keeps existing certificates working until they expire.Notable change
Node.js now honours Mozilla's distrust-after dates for roots in the bundled store. TLS server certificates issued by emSign Root CA - G1 after 2026-11-16, by Izenpe.com after 2026-04-15, or by Firmaprofesional CIF A62634068 after 2026-08-06 are rejected with
CERT_REVOKED, matching Firefox. Certificates issued before those dates keep working until they expire, and client certificates are not affected.Contributed by Ulises Gascón in #67412.
Context