From c836157edb869e80b15f51bb8f48725e3b898b9a Mon Sep 17 00:00:00 2001 From: syuilo Date: Fri, 22 Sep 2023 14:12:33 +0900 Subject: enhance: 二要素認証設定時のセキュリティを強化 (#11863) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * enhance: 二要素認証設定時のセキュリティを強化 パスワード入力が必要な操作を行う際、二要素認証が有効であれば確認コードの入力も必要にする * Update CoreModule.ts * Update 2fa.ts * wip * wip * Update 2fa.ts * tweak --- packages/frontend/src/pages/settings/other.vue | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) (limited to 'packages/frontend/src/pages/settings/other.vue') diff --git a/packages/frontend/src/pages/settings/other.vue b/packages/frontend/src/pages/settings/other.vue index c3278c22f3..e2fc021099 100644 --- a/packages/frontend/src/pages/settings/other.vue +++ b/packages/frontend/src/pages/settings/other.vue @@ -113,14 +113,12 @@ async function deleteAccount() { if (canceled) return; } - const { canceled, result: password } = await os.inputText({ - title: i18n.ts.password, - type: 'password', - }); - if (canceled) return; + const auth = await os.authenticateDialog(); + if (auth.canceled) return; await os.apiWithDialog('i/delete-account', { - password: password, + password: auth.result.password, + token: auth.result.token, }); await os.alert({ -- cgit v1.2.3-freya