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

feat: ウインドウの作成とナビゲーションを無効化する #2154

Merged

Conversation

sabonerune
Copy link
Contributor

内容

Electronのベストプラクティスに基づきセキュリティを強化します。
13. ナビゲーションを無効化か制限
14. 新規ウインドウの作成を無効化か制限
15. 信用されないコンテンツで shell.openExternal を使用しない
(部分的)

その他

ナビゲーションと新規ウインドウ作成は現状することはないはずなので無効化します。

shell.openExternalhttp:https:の場合に実行します。
これはmailto:などを拒否してしまう一方で危険なURLでも問答無用で開いてしまいます。

@sabonerune sabonerune requested a review from a team as a code owner July 2, 2024 22:34
@sabonerune sabonerune requested review from Hiroshiba and removed request for a team July 2, 2024 22:34
Copy link
Member

@Hiroshiba Hiroshiba left a comment

Choose a reason for hiding this comment

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

LGTM!!

ありがとうございます!!
マルチエンジン機能を使えばHTMLがレンダリングできるので、その周りの悪意ある処理を防げるかもですね!

動かしてないけどたぶん問題ないはず・・・!!!

src/backend/electron/main.ts Outdated Show resolved Hide resolved
@Hiroshiba Hiroshiba merged commit d2f0cbe into VOICEVOX:main Jul 3, 2024
8 checks passed
@sabonerune sabonerune deleted the feat/disable-new-window-and-navigation branch July 3, 2024 22:04
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

Successfully merging this pull request may close these issues.

2 participants