diff --git a/src/DeviceListener.js b/src/DeviceListener.js index d2ba8219db..27caba971e 100644 --- a/src/DeviceListener.js +++ b/src/DeviceListener.js @@ -225,14 +225,6 @@ export default class DeviceListener { }); } } - } else if (await cli.secretStorageKeyNeedsUpgrade()) { - ToastStore.sharedInstance().addOrReplaceToast({ - key: THIS_DEVICE_TOAST_KEY, - title: _t("Encryption upgrade available"), - icon: "verification_warning", - props: {kind: 'upgrade_ssss'}, - component: sdk.getComponent("toasts.SetupEncryptionToast"), - }); } else { // cross-signing is ready, and we don't need to upgrade encryption ToastStore.sharedInstance().dismissToast(THIS_DEVICE_TOAST_KEY); diff --git a/src/components/views/settings/CrossSigningPanel.js b/src/components/views/settings/CrossSigningPanel.js index c07f1c25dd..b1642e260d 100644 --- a/src/components/views/settings/CrossSigningPanel.js +++ b/src/components/views/settings/CrossSigningPanel.js @@ -36,7 +36,6 @@ export default class CrossSigningPanel extends React.PureComponent { userSigningPrivateKeyCached: false, sessionBackupKeyCached: false, secretStorageKeyInAccount: false, - secretStorageKeyNeedsUpgrade: null, }; } @@ -88,7 +87,6 @@ export default class CrossSigningPanel extends React.PureComponent { const homeserverSupportsCrossSigning = await cli.doesServerSupportUnstableFeature("org.matrix.e2e_cross_signing"); const crossSigningReady = await cli.isCrossSigningReady(); - const secretStorageKeyNeedsUpgrade = await cli.secretStorageKeyNeedsUpgrade(); this.setState({ crossSigningPublicKeysOnDevice, @@ -100,7 +98,6 @@ export default class CrossSigningPanel extends React.PureComponent { secretStorageKeyInAccount, homeserverSupportsCrossSigning, crossSigningReady, - secretStorageKeyNeedsUpgrade, }); } @@ -150,7 +147,6 @@ export default class CrossSigningPanel extends React.PureComponent { secretStorageKeyInAccount, homeserverSupportsCrossSigning, crossSigningReady, - secretStorageKeyNeedsUpgrade, } = this.state; let errorSection; @@ -259,10 +255,6 @@ export default class CrossSigningPanel extends React.PureComponent { {_t("Homeserver feature support:")} {homeserverSupportsCrossSigning ? _t("exists") : _t("not found")} - - {_t("Secret Storage key format:")} - {secretStorageKeyNeedsUpgrade ? _t("outdated") : _t("up to date")} - {errorSection} diff --git a/src/components/views/toasts/SetupEncryptionToast.js b/src/components/views/toasts/SetupEncryptionToast.js index 75fd55378c..b5510e85b6 100644 --- a/src/components/views/toasts/SetupEncryptionToast.js +++ b/src/components/views/toasts/SetupEncryptionToast.js @@ -17,7 +17,6 @@ limitations under the License. import React from 'react'; import PropTypes from 'prop-types'; import Modal from '../../../Modal'; -import { MatrixClientPeg } from '../../../MatrixClientPeg'; import * as sdk from "../../../index"; import { _t } from '../../../languageHandler'; import DeviceListener from '../../../DeviceListener'; @@ -31,7 +30,6 @@ export default class SetupEncryptionToast extends React.PureComponent { 'set_up_encryption', 'verify_this_session', 'upgrade_encryption', - 'upgrade_ssss', ]).isRequired, }; @@ -39,24 +37,6 @@ export default class SetupEncryptionToast extends React.PureComponent { DeviceListener.sharedInstance().dismissEncryptionSetup(); }; - async _waitForCompletion() { - if (this.props.kind === 'upgrade_ssss') { - return new Promise(resolve => { - const recheck = async () => { - const needsUpgrade = await MatrixClientPeg.get().secretStorageKeyNeedsUpgrade(); - if (!needsUpgrade) { - MatrixClientPeg.get().removeListener('accountData', recheck); - resolve(); - } - }; - MatrixClientPeg.get().on('accountData', recheck); - recheck(); - }); - } else { - return; - } - } - _onSetupClick = async () => { if (this.props.kind === "verify_this_session") { Modal.createTrackedDialog('Verify session', 'Verify session', SetupEncryptionDialog, @@ -68,7 +48,6 @@ export default class SetupEncryptionToast extends React.PureComponent { ); try { await accessSecretStorage(); - await this._waitForCompletion(); } finally { modal.close(); } @@ -82,8 +61,6 @@ export default class SetupEncryptionToast extends React.PureComponent { return _t('Verify yourself & others to keep your chats safe'); case 'verify_this_session': return _t('Other users may not trust it'); - case 'upgrade_ssss': - return _t('Update your secure storage'); } } @@ -92,7 +69,6 @@ export default class SetupEncryptionToast extends React.PureComponent { case 'set_up_encryption': return _t('Set up'); case 'upgrade_encryption': - case 'upgrade_ssss': return _t('Upgrade'); case 'verify_this_session': return _t('Verify'); diff --git a/src/i18n/strings/en_EN.json b/src/i18n/strings/en_EN.json index 99e43e0881..61a27847c8 100644 --- a/src/i18n/strings/en_EN.json +++ b/src/i18n/strings/en_EN.json @@ -569,7 +569,6 @@ "Review": "Review", "Verify yourself & others to keep your chats safe": "Verify yourself & others to keep your chats safe", "Other users may not trust it": "Other users may not trust it", - "Update your secure storage": "Update your secure storage", "Set up": "Set up", "Upgrade": "Upgrade", "Verify": "Verify", @@ -621,9 +620,6 @@ "in account data": "in account data", "Homeserver feature support:": "Homeserver feature support:", "exists": "exists", - "Secret Storage key format:": "Secret Storage key format:", - "outdated": "outdated", - "up to date": "up to date", "Your homeserver does not support session management.": "Your homeserver does not support session management.", "Unable to load session list": "Unable to load session list", "Confirm deleting these sessions by using Single Sign On to prove your identity.|other": "Confirm deleting these sessions by using Single Sign On to prove your identity.",