Remove dependency on org.matrix.e2e_cross_signing unstable feature (#10593)

* Remove dependency on `org.matrix.e2e_cross_signing` unstable feature

Currently, we have some code that relies on the server declaring support for an
`unstable_feature` called `org.matrix.e2e_cross_signing`. There is nothing in
the spec that requires this, so this would make us incompatible with some
server implementations.

The features in question were added in spec v1.1, so we can test for that
instead.

* fix unit test
This commit is contained in:
Richard van der Hoff 2023-04-14 11:14:05 +01:00 committed by GitHub
parent 70b87f8bde
commit 6b451afc50
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
4 changed files with 5 additions and 10 deletions

View file

@ -132,9 +132,6 @@ async function getCryptoContext(client: MatrixClient): Promise<CryptoContext> {
return {
device_keys: keys.join(", "),
cross_signing_ready: String(await client.isCrossSigningReady()),
cross_signing_supported_by_hs: String(
await client.doesServerSupportUnstableFeature("org.matrix.e2e_cross_signing"),
),
cross_signing_key: crossSigning.getId()!,
cross_signing_privkey_in_secret_storage: String(!!(await crossSigning.isStoredInSecretStorage(secretStorage))),
cross_signing_master_privkey_cached: String(!!(pkCache && (await pkCache.getCrossSigningKeyCache?.("master")))),