Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: make child windows not crash when ipc messages are received #19633

Conversation

@trop
Copy link
Contributor

commented Aug 5, 2019

Backport of #19553

See that PR for details.

Notes: Fixed case where sending IPC to a child window (opened with window.open) could cause a crash

MarshallOfSound and others added some commits Jul 31, 2019

fix: make child windows not crash when ipc messages are received
This also adds a path forward for apps using child windows with
nodeIntegration to migrate into a non-leaky way of doing it.

1. Ensure that if ipcNative is missing we don't crash rather log that it
is missing
2. Add a hidden option `--enable-node-leakage-in-renderers` (temporary
measure) to allow app devs to opt in to leaking node in child windows
3. Bypasses the Opener() check if renderer process reuse is enabled
(which would prevent the leak anyway)

So the path forward is: it no longer crashes --> folks use the hidden
option --> folks opt in to renderer process reuse.
Apply suggestions from code review
Co-Authored-By: Jeremy Apthorp <jeremya@chromium.org>
Update shell/renderer/atom_renderer_client.cc
Co-Authored-By: Jeremy Apthorp <jeremya@chromium.org>

@codebytere codebytere merged commit ab83309 into 6-0-x Aug 5, 2019

14 checks passed

Artifact Comparison No Changes
Details
Semantic Pull Request ready to be squashed
Details
Valid Backport Valid Backport
Details
WIP Ready for review
Details
appveyor: win-ia32-testing AppVeyor build succeeded
Details
appveyor: win-ia32-testing-pr AppVeyor build succeeded
Details
appveyor: win-x64-testing AppVeyor build succeeded
Details
appveyor: win-x64-testing-pr AppVeyor build succeeded
Details
build-linux Workflow: build-linux
Details
build-mac Workflow: build-mac
Details
electron-arm-testing Build #20190805.37 succeeded
Details
electron-arm64-testing Build #20190805.37 succeeded
Details
lint Workflow: lint
Details
release-notes Release notes found
@release-clerk

This comment has been minimized.

Copy link

commented Aug 5, 2019

Release Notes Persisted

Fixed case where sending IPC to a child window (opened with window.open) could cause a crash

@codebytere codebytere deleted the trop/6-0-x-bp-fix-make-child-windows-not-crash-when-ipc-messages-are-received-1565034668489 branch Aug 5, 2019

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
2 participants
You can’t perform that action at this time.