1
0
mirror of https://github.com/bitwarden/browser synced 2025-12-12 14:23:32 +00:00

url encode data from msg_handler content script (#2170)

This commit is contained in:
Kyle Spearrin
2021-11-09 12:26:17 -05:00
committed by GitHub
parent d71c945d8b
commit 0039d4aaea

View File

@@ -138,7 +138,7 @@ export default class RuntimeBackground {
try {
BrowserApi.createNewTab('popup/index.html?uilocation=popout#/sso?code=' +
msg.code + '&state=' + msg.state);
encodeURIComponent(msg.code) + '&state=' + encodeURIComponent(msg.state));
}
catch {
this.logService.error('Unable to open sso popout tab');
@@ -151,7 +151,8 @@ export default class RuntimeBackground {
return;
}
const params = `webAuthnResponse=${encodeURIComponent(msg.data)};remember=${msg.remember}`;
const params = `webAuthnResponse=${encodeURIComponent(msg.data)};` +
`remember=${encodeURIComponent(msg.remember)}`;
BrowserApi.createNewTab(`popup/index.html?uilocation=popout#/2fa;${params}`, undefined, false);
break;
case 'reloadPopup':