feat: add security warnings to sandboxed renderers (#14869)

Also refactor not to use the remote module.
This commit is contained in:
Milan Burda 2018-10-03 21:36:12 +02:00 committed by Alexey Kuzmin
parent de020d0a5e
commit 5efb0fdff1
5 changed files with 327 additions and 224 deletions

View file

@ -475,3 +475,11 @@ ipcMain.on('ELECTRON_BROWSER_SANDBOX_LOAD', function (event) {
}
}
})
ipcMain.on('ELECTRON_BROWSER_GET_LAST_WEB_PREFERENCES', function (event) {
try {
event.returnValue = [null, event.sender.getLastWebPreferences()]
} catch (error) {
event.returnValue = [errorUtils.serialize(error)]
}
})