chore: bump core crypto to v9.2.1 - WPB-20920#4030
chore: bump core crypto to v9.2.1 - WPB-20920#4030netbe merged 23 commits intorelease/cycle-4.16from
Conversation
There was a problem hiding this comment.
Pull request overview
This PR upgrades the core crypto dependency and removes the SafeCoreCrypto wrapper class, which is now redundant since core crypto v9.x handles safe multi-process access internally. The main changes include replacing SafeCoreCryptoProtocol with direct CoreCryptoProtocol usage, renaming the transaction method from perform to transaction, and updating error constructors to use named parameters.
Key changes:
- Removed
SafeCoreCryptowrapper class and its tests - Updated all usages to directly use
CoreCryptoProtocolinstead ofSafeCoreCryptoProtocol - Changed method calls from
performtotransactionthroughout the codebase - Updated CoreCrypto error constructors to use named parameters (e.g.,
errorCode:,mlsError:,msg:)
Reviewed changes
Copilot reviewed 50 out of 51 changed files in this pull request and generated 1 comment.
Show a summary per file
| File | Description |
|---|---|
| WireCoreCrypto/Package.swift | Updated core crypto framework URLs and checksums to v9.1.2 |
| wire-ios-data-model/Support/Sources/MockSafeCoreCrypto.swift | Removed redundant SafeCoreCrypto mock class |
| wire-ios-data-model/Support/Sources/MockCoreCryptoProtocol.swift | Added mockTransaction helper method and updated transaction method signature |
| wire-ios-data-model/Support/Sourcery/generated/AutoMockable.generated.swift | Updated generated mocks to reflect CoreCryptoProtocol return type and removed proteusCryptoboxMigrate method |
| wire-ios-data-model/Source/Utilis/CoreCryptoContextProtocolExt.swift | Removed proteusCryptoboxMigrate method and added documentation for new methods |
| wire-ios-data-model/Source/ManagedObjectContext/NSManagedObjectContext+CoreCrypto.swift | Changed property type from SafeCoreCryptoProtocol to CoreCryptoProtocol |
| wire-ios-data-model/Source/Proteus/ProteusService.swift | Updated to use CoreCryptoProtocol and transaction method instead of perform |
| wire-ios-data-model/Source/MLS/MLSService.swift | Updated to use CoreCryptoProtocol and transaction method |
| wire-ios-data-model/Source/MLS/MLSEncryptionService.swift | Updated to use CoreCryptoProtocol and transaction method |
| wire-ios-data-model/Source/MLS/MLSActionExecutor.swift | Updated to use CoreCryptoProtocol, transaction method, and updated error constructor |
| wire-ios-data-model/Source/MLS/CreateMLSGroupUseCase.swift | Updated to use CoreCryptoProtocol and transaction method |
| wire-ios-data-model/Source/E2EIdentity/E2EIVerificationStatusService.swift | Updated to use CoreCryptoProtocol and transaction method |
| wire-ios-data-model/Source/E2EIdentity/E2EISetupService.swift | Updated to use CoreCryptoProtocol and transaction method |
| wire-ios-data-model/Source/E2EIdentity/E2EIService.swift | Updated to use CoreCryptoProtocol |
| wire-ios-data-model/Source/UseCases/IsUserE2EICertifiedUseCase.swift | Updated to use transaction method |
| wire-ios-data-model/WireDataModel.xcodeproj/project.pbxproj | Removed SafeCoreCrypto.swift and SafeCoreCryptoTests.swift from build targets |
| wire-ios-data-model/Tests/**/*.swift | Updated all test files to use MockCoreCryptoProtocol with mockTransaction helper, removed MockSafeCoreCrypto usage, and updated error constructors to use named parameters |
| wire-ios-sync-engine/Source/UserSession/NSManagedObject+CryptoStack.swift | Removed explicit tearDown call for coreCrypto |
| wire-ios-sync-engine/Tests/**/*.swift | Updated test files to use MockCoreCryptoProtocol instead of MockSafeCoreCrypto |
| wire-ios-request-strategy/Sources/E2EIdentity/E2EIKeyPackageRotator.swift | Updated to use CoreCryptoProtocol and transaction method |
| wire-ios-request-strategy/Tests/Helpers/*.swift | Updated test helpers to use CoreCrypto instead of SafeCoreCrypto and removed tearDown calls |
| WireDomain/Sources/WireDomain/Synchronization/*.swift | Updated synchronization components to use transaction method |
| WireDomain/Tests/WireDomainTests/Synchronization/*.swift | Updated test files to use MockCoreCryptoProtocol with mockTransaction |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Test Results 7 files 978 suites 9m 44s ⏱️ Results for commit ee52df4. ♻️ This comment has been updated with latest results. Summary: workflow run #22317761743 |
|
This PR is stale because it has been open 30 days with no activity. Please update it or close it in case is not relevant anymore. |
# Conflicts: # wire-ios-data-model/Source/Core Crypto/SafeCoreCrypto.swift # wire-ios-data-model/Support/Sources/MockSafeCoreCrypto.swift # wire-ios-data-model/Tests/Core Crypto/SafeCoreCryptoTests.swift # wire-ios-request-strategy/Tests/Helpers/MessagingTestBase.swift # wire-ios-sync-engine/Tests/Source/E2EE/UserClientEventConsumerTests.swift
netbe
left a comment
There was a problem hiding this comment.
left some comments before approving
David-Henner
left a comment
There was a problem hiding this comment.
Looks good 👍 Thanks for taking over @netbe
Add logging for proteus initialization in transaction.
|
Co-authored-by: François Benaiteau <francois.benaiteau@wire.com> Co-authored-by: François Benaiteau <netbe@users.noreply.github.com>



Issue
Bumping core crypto to version
9.2.1.9.1.2Core crypto now handles safe multi-process access, so
SafeCoreCryptobecomes redundant, hence why we're removing it in this PRTesting
Creating channels, sending messages, adding / removing users
Checklist
[WPB-XXX].