diff --git a/src/components/structures/MatrixChat.js b/src/components/structures/MatrixChat.js index de916ad7aa..339ea279ee 100644 --- a/src/components/structures/MatrixChat.js +++ b/src/components/structures/MatrixChat.js @@ -1375,7 +1375,8 @@ export default createReactClass({ cancelButton: _t('Dismiss'), onFinished: (confirmed) => { if (confirmed) { - window.open(consentUri, '_blank'); + const wnd = window.open(consentUri, '_blank'); + wnd.opener = null; } }, }, null, true); diff --git a/src/components/views/auth/InteractiveAuthEntryComponents.js b/src/components/views/auth/InteractiveAuthEntryComponents.js index 0b89c82658..aaf8c88440 100644 --- a/src/components/views/auth/InteractiveAuthEntryComponents.js +++ b/src/components/views/auth/InteractiveAuthEntryComponents.js @@ -604,6 +604,7 @@ export const FallbackAuthEntry = createReactClass({ this.props.authSessionId, ); this._popupWindow = window.open(url); + this._popupWindow.opener = null; }, _onReceiveMessage: function(event) { diff --git a/src/components/views/messages/TextualBody.js b/src/components/views/messages/TextualBody.js index d74170919e..ac0fc65ff4 100644 --- a/src/components/views/messages/TextualBody.js +++ b/src/components/views/messages/TextualBody.js @@ -374,7 +374,9 @@ export default createReactClass({ const height = window.screen.height > 800 ? 800 : window.screen.height; const left = (window.screen.width - width) / 2; const top = (window.screen.height - height) / 2; - window.open(completeUrl, '_blank', `height=${height}, width=${width}, top=${top}, left=${left},`); + const features = `height=${height}, width=${width}, top=${top}, left=${left},`; + const wnd = window.open(completeUrl, '_blank', features); + wnd.opener = null; }, }); });