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

Should preload.js be made secure? #7

Closed
srymh opened this issue May 7, 2021 · 2 comments
Closed

Should preload.js be made secure? #7

srymh opened this issue May 7, 2021 · 2 comments

Comments

@srymh
Copy link
Owner

srymh commented May 7, 2021

https://www.electronjs.org/docs/tutorial/context-isolation#security-considerations

Security Considerations

Just enabling contextIsolation and using contextBridge does not automatically mean that everything you do is safe. For instance this code is unsafe.
...
It directly exposes a powerful API without any kind of argument filtering. This would allow any website to send arbitrary IPC messages which you do not want to be possible. The correct way to expose IPC-based APIs would instead be to provide one method per IPC message.
...

@srymh
Copy link
Owner Author

srymh commented May 7, 2021

For now preload.js is copied from here:

electron/electron#9920 (comment)

@srymh
Copy link
Owner Author

srymh commented May 15, 2023

No

@srymh srymh closed this as completed May 15, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant