* Convert RecoveryMethodRemovedDialog to TS
Signed-off-by: Šimon Brandner <simon.bra.ag@gmail.com>
* Convert NewRecoveryMethodDialog to TS
Signed-off-by: Šimon Brandner <simon.bra.ag@gmail.com>
* Convert ImportE2eKeysDialog to TS
Signed-off-by: Šimon Brandner <simon.bra.ag@gmail.com>
* Convert ExportE2eKeysDialog to TS
Signed-off-by: Šimon Brandner <simon.bra.ag@gmail.com>
* Convert CreateSecretStorageDialog to TS
Signed-off-by: Šimon Brandner <simon.bra.ag@gmail.com>
* Convert CreateKeyBackupDialog to TS
Signed-off-by: Šimon Brandner <simon.bra.ag@gmail.com>
* Fix types
This is somewhat hacky though I don't know of a better way to do this
Signed-off-by: Šimon Brandner <simon.bra.ag@gmail.com>
This migrates one bucket of files using some amount of Flow typing to mark them
as TypeScript instead. The remaining type errors are fixed in subsequent
commits.
Turns out a lot of the typescript warnings about improper warnings were correct. TypeScript appears to be pulling in two copies of the js-sdk when we do this, which can lead to type conflicts (or worse: the wrong code entirely). We fix this at the webpack level by explicitly importing from `src`, but some alternative build structures have broken tests because of this - jest ends up pulling in the "wrong" js-sdk, breaking things.
This adds various customisations point in the app for security related
decisions. By default, these do nothing, but would be customised at the
app level via module replacement (so that no changes are needed here in the
SDK).
Fixes https://github.com/vector-im/element-web/issues/15350
This adds support for the `secure_backup_setup_methods` key, which allows HS
admins to state that Element should simplify down to only one setup method,
rather than offering both.
Fixes https://github.com/vector-im/element-web/issues/15238
With this change, Element now creates cross-signing keys during auth flows for
password login. For other auth flows like token / SSO, it will not happen until
a cross-signing / secret storage dialog flow as before.
This adds set up and reset actions to each of cross-signing and secure backup
that do separate things, rather than mixing concerns together. (It's temporarily
still a bit of lie for backup, as more changes are needed to stop resetting
cross-signing as well.)
This supplies a cache callback to the JS SDK so that we can be notified if a new
storage key is created e.g. by resetting secret storage. This allows it to be
supplied automatically in case it's needed in the same user operation, as it is
when resetting both secret storage and cross-signing together.
This migrates to the new JS SDK APIs, which now use separate paths for
cross-signing and secret storage setup. There should be no functional change
here.
Part of https://github.com/vector-im/element-web/issues/13895