Skip to content

fix: Enable X509_V_FLAG_TRUSTED_FIRST flag in BoringSSL - #31213

Merged
MarshallOfSound merged 1 commit into
electron:mainfrom
jviotti:enable-x509-trusted-first-flag
Sep 30, 2021
Merged

MarshallOfSound merged 1 commit into
electron:mainfrom
jviotti:enable-x509-trusted-first-flag

Conversation

@jviotti

@jviotti jviotti commented Sep 30, 2021 •

Copy link
Copy Markdown
Contributor

This flag is set by default on OpenSSL.

Fixes: #31212
Signed-off-by: Juan Cruz Viotti [email protected]

Release Notes

Notes: Fix Let's Encrypt DST Root CA X3 certificate expiration.

@jviotti
jviotti requested a review from a team as a code owner September 30, 2021 18:00
@electron-cation electron-cation Bot added the new-pr 🌱 PR opened recently label Sep 30, 2021
@jviotti

jviotti commented Sep 30, 2021

Copy link
Copy Markdown
Contributor Author

We are planning to work on a test case, but probably as another PR just to get this one merged given its urgency

@VerteDinde VerteDinde added the fast-track 🚅 Indicates that this PR is intended to bypass the 24 hour rule. Needs approval from Releases label Sep 30, 2021
@electron-cation electron-cation Bot removed the new-pr 🌱 PR opened recently label Sep 30, 2021
@VerteDinde
VerteDinde requested a review from a team September 30, 2021 18:06

@MarshallOfSound MarshallOfSound left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm somewhat concerned that the bug only impacts the nodejs http module but this patch impacts every consumer of boringssl. Is there any way to patch this in to node specifically?

@codebytere

Copy link
Copy Markdown
Member

cc @davidben - do you think this is the right fix?

@jviotti

jviotti commented Sep 30, 2021

Copy link
Copy Markdown
Contributor Author

@MarshallOfSound

I'm somewhat concerned that the bug only impacts the nodejs http module but this patch impacts every consumer of boringssl. Is there any way to patch this in to node specifically?

Yeah, I get your point. On the other hand, every consumer of BoringSSL that doesn't overwrite the default flags would face the same problem, right? To your point, Chromium does seem to work by default, so I guess they already overwrite it in all places?

@jkleinsc jkleinsc added the semver/patch backwards-compatible bug fixes label Sep 30, 2021
@clavin

clavin commented Sep 30, 2021

Copy link
Copy Markdown
Member

Compiled a test build with this patch. I can confirm I was able to successfully make a request to https://letsencrypt.org using https.get with this patch from node in the main process.

@laurent22

Copy link
Copy Markdown

If you merge this please consider backporting the fix to previous Electron versions. In our case, we are somewhat stuck at version 10 due to the Electron sandbox changes. We'll upgrade some day but it's not trivial, and I'm sure many people likewise don't have the resources to upgrade to a major version, yet would certainly consider upgrading to a patch version.

@VerteDinde

VerteDinde commented Sep 30, 2021 •

Copy link
Copy Markdown
Member

@laurent22 We're planning on backporting the fix into all of our current stable release lines (Electron 12-15) and beta line (Electron 16) 👍 If people reading have concerns, let's discuss in the original issue so we don't distract from any fix discussions here 🙂

@MarshallOfSound MarshallOfSound left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@MarshallOfSound
MarshallOfSound merged commit 0e042ca into electron:main Sep 30, 2021
@release-clerk

release-clerk Bot commented Sep 30, 2021

Copy link
Copy Markdown

Release Notes Persisted

Fix Let's Encrypt DST Root CA X3 certificate expiration.

@jviotti
jviotti deleted the enable-x509-trusted-first-flag branch September 30, 2021 20:22
@trop

trop Bot commented Sep 30, 2021

Copy link
Copy Markdown
Contributor

I have automatically backported this PR to "12-x-y", please check out #31214

@marxin

marxin commented Oct 1, 2021

Copy link
Copy Markdown

Are you planning to make the change in the upstream BoringSSL library:
https://boringssl.googlesource.com/boringssl
?

@deepak1556

Copy link
Copy Markdown
Member

@GermanCoding

Copy link
Copy Markdown

Yeah, I get your point. On the other hand, every consumer of BoringSSL that doesn't overwrite the default flags would face the same problem, right? To your point, Chromium does seem to work by default, so I guess they already overwrite it in all places?

Chromium has it's own verifier code and doesn't use BoringSSL at all for this purpose - which is also why it's not affected..

@Ciberusps

Copy link
Copy Markdown

@VerteDinde

Do u plan to backport fix for electron v8 & v11 also?

@zeeker999

zeeker999 commented Oct 2, 2021 •

Copy link
Copy Markdown
Contributor

Could you please backport this to v11 as well? Our product is still using the v11 since some bugs(for example #30666 and #31016) are unfixed and we can't upgrade to the latest stable for the moment.

Sorry to ping you, I'm not sure to ping which one since this bug should affect all stable releases and the electron team should take action now.
@MarshallOfSound

@foxt

foxt commented Oct 6, 2021

Copy link
Copy Markdown
Contributor

We're also requesting a backport to V9 if at all possible.

t57ser pushed a commit to t57ser/electron that referenced this pull request Oct 27, 2021
t57ser pushed a commit to t57ser/electron that referenced this pull request Oct 27, 2021
t57ser pushed a commit to t57ser/electron that referenced this pull request Oct 29, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

fast-track 🚅 Indicates that this PR is intended to bypass the 24 hour rule. Needs approval from Releases semver/patch backwards-compatible bug fixes

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Bug]: Let's Encrypt root CA isn't working properly