Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

crypto: configure key sharing strategy based on DeviceIsolationMode #4425

Merged
merged 7 commits into from
Sep 30, 2024

Conversation

BillCarsonFr
Copy link
Member

@BillCarsonFr BillCarsonFr commented Sep 23, 2024

Fixes element-hq/element-web#28038
based on the work done on #4407

Checklist

  • Tests written for new code (and old code if feasible).
  • New or updated public/exported symbols have accurate TSDoc documentation.
  • Linter and other CI checks pass.
  • Sign-off given on the changes (see CONTRIBUTING.md).

@richvdh
Copy link
Member

richvdh commented Sep 23, 2024

Will need to be updated in light of #4428

@BillCarsonFr BillCarsonFr force-pushed the valere/invisible_crypto_decryption_flag branch from 2be0544 to 4050919 Compare September 25, 2024 09:08
@BillCarsonFr BillCarsonFr requested a review from a team as a code owner September 25, 2024 09:08
@BillCarsonFr BillCarsonFr force-pushed the valere/invisible_crypto_decryption_flag branch from 4050919 to 5e43195 Compare September 25, 2024 14:04
@BillCarsonFr BillCarsonFr changed the title crypto: configure key sharing strategy based on cryptoMode crypto: configure key sharing strategy based on DeviceIsolationMode Sep 25, 2024
fix eslint import error

cryptoMode was renamed to deviceIsolationMode

post rebase fix: Device Isolation mode name changes
@BillCarsonFr BillCarsonFr force-pushed the valere/invisible_crypto_decryption_flag branch from 5e43195 to 87f5304 Compare September 25, 2024 14:49
@BillCarsonFr
Copy link
Member Author

Will need to be updated in light of #4428

Done

Copy link
Member

@richvdh richvdh left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

looks good to me in general. A couple of nits

spec/unit/rust-crypto/RoomEncryptor.spec.ts Outdated Show resolved Hide resolved
public async prepareForEncryption(globalBlacklistUnverifiedDevices: boolean): Promise<void> {
public async prepareForEncryption(
globalBlacklistUnverifiedDevices: boolean,
deviceIsolationMode: DeviceIsolationMode = new AllDevicesIsolationMode(false),
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

given that this is only called in one place (except in tests), we should not provide a default value.

Likewise below.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

src/rust-crypto/RoomEncryptor.ts Outdated Show resolved Hide resolved
src/rust-crypto/RoomEncryptor.ts Outdated Show resolved Hide resolved
src/rust-crypto/RoomEncryptor.ts Outdated Show resolved Hide resolved
src/rust-crypto/RoomEncryptor.ts Outdated Show resolved Hide resolved
@richvdh
Copy link
Member

richvdh commented Sep 30, 2024

LGTM otherwise

@richvdh richvdh added this pull request to the merge queue Sep 30, 2024
Merged via the queue into develop with commit 9ecb66e Sep 30, 2024
26 checks passed
@richvdh richvdh deleted the valere/invisible_crypto_decryption_flag branch September 30, 2024 14:45
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
T-Task Tasks for the team like planning
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Invisible Crypto | configure key sharing strategy based on labs feature flag
2 participants