mirror of
https://github.com/Novaloop-AG/element-x-ios.git
synced 2026-11-04 19:44:05 +00:00
Bump the RustSDK, bump the app minor version and force user logout
This commit is contained in:
committed by
Stefan Ceriu
parent
bb18ed1e91
commit
2359910857
@@ -112,7 +112,7 @@
|
|||||||
"location" : "https://github.com/matrix-org/matrix-rust-components-swift",
|
"location" : "https://github.com/matrix-org/matrix-rust-components-swift",
|
||||||
"state" : {
|
"state" : {
|
||||||
"revision" : "9650501c92a1ed802a757f2c6807a36d59619f43",
|
"revision" : "9650501c92a1ed802a757f2c6807a36d59619f43",
|
||||||
"version" : "1.0.49-alpha"
|
"version" : "1.0.50-alpha"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
@@ -163,7 +163,7 @@
|
|||||||
{
|
{
|
||||||
"identity" : "swift-snapshot-testing",
|
"identity" : "swift-snapshot-testing",
|
||||||
"kind" : "remoteSourceControl",
|
"kind" : "remoteSourceControl",
|
||||||
"location" : "https://github.com/pointfreeco/swift-snapshot-testing.git",
|
"location" : "https://github.com/pointfreeco/swift-snapshot-testing",
|
||||||
"state" : {
|
"state" : {
|
||||||
"revision" : "cef5b3f6f11781dd4591bdd1dd0a3d22bd609334",
|
"revision" : "cef5b3f6f11781dd4591bdd1dd0a3d22bd609334",
|
||||||
"version" : "1.11.0"
|
"version" : "1.11.0"
|
||||||
|
|||||||
@@ -136,11 +136,9 @@ class AppCoordinator: AppCoordinatorProtocol {
|
|||||||
private func performMigrationsIfNecessary(from oldVersion: Version, to newVersion: Version) {
|
private func performMigrationsIfNecessary(from oldVersion: Version, to newVersion: Version) {
|
||||||
guard oldVersion != newVersion else { return }
|
guard oldVersion != newVersion else { return }
|
||||||
|
|
||||||
if oldVersion < Version(1, 0, 20) {
|
if oldVersion < Version(1, 1, 0) {
|
||||||
// Version 1.0.20 introduced a new format for restoration tokens.
|
// Version 1.1.0 switched the Rust crypto store to SQLite
|
||||||
// Remove user data to prevent conflict in the crypto store
|
// There are no migrations in place so we need to reset everything
|
||||||
// with the newly generated device ID when signing in again.
|
|
||||||
MXLog.warning("Clearing user data for hardcoded proxy.")
|
|
||||||
wipeUserData()
|
wipeUserData()
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -36,6 +36,7 @@ final class AppSettings: ObservableObject {
|
|||||||
private static var store: UserDefaults! = UserDefaults(suiteName: suiteName)
|
private static var store: UserDefaults! = UserDefaults(suiteName: suiteName)
|
||||||
|
|
||||||
static func reset() {
|
static func reset() {
|
||||||
|
MXLog.warning("Resetting the AppSettings.")
|
||||||
store.removePersistentDomain(forName: suiteName)
|
store.removePersistentDomain(forName: suiteName)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -68,6 +68,8 @@ class KeychainController: KeychainControllerProtocol {
|
|||||||
}
|
}
|
||||||
|
|
||||||
func removeRestorationTokenForUsername(_ username: String) {
|
func removeRestorationTokenForUsername(_ username: String) {
|
||||||
|
MXLog.warning("Removing restoration token for user: \(username).")
|
||||||
|
|
||||||
do {
|
do {
|
||||||
try keychain.remove(username)
|
try keychain.remove(username)
|
||||||
} catch {
|
} catch {
|
||||||
@@ -76,6 +78,8 @@ class KeychainController: KeychainControllerProtocol {
|
|||||||
}
|
}
|
||||||
|
|
||||||
func removeAllRestorationTokens() {
|
func removeAllRestorationTokens() {
|
||||||
|
MXLog.warning("Removing all user restoration tokens.")
|
||||||
|
|
||||||
do {
|
do {
|
||||||
try keychain.removeAll()
|
try keychain.removeAll()
|
||||||
} catch {
|
} catch {
|
||||||
|
|||||||
@@ -38,6 +38,7 @@ class UserSessionStore: UserSessionStoreProtocol {
|
|||||||
|
|
||||||
/// Deletes all data stored in the shared container and keychain
|
/// Deletes all data stored in the shared container and keychain
|
||||||
func reset() {
|
func reset() {
|
||||||
|
MXLog.warning("Resetting the UserSessionStore. All accounts will be affected.")
|
||||||
try? FileManager.default.removeItem(at: baseDirectory)
|
try? FileManager.default.removeItem(at: baseDirectory)
|
||||||
keychainController.removeAllRestorationTokens()
|
keychainController.removeAllRestorationTokens()
|
||||||
}
|
}
|
||||||
|
|||||||
+2
-2
@@ -27,7 +27,7 @@ settings:
|
|||||||
APP_GROUP_IDENTIFIER: group.$(BASE_APP_GROUP_IDENTIFIER)
|
APP_GROUP_IDENTIFIER: group.$(BASE_APP_GROUP_IDENTIFIER)
|
||||||
BASE_BUNDLE_IDENTIFIER: io.element.elementx
|
BASE_BUNDLE_IDENTIFIER: io.element.elementx
|
||||||
KEYCHAIN_ACCESS_GROUP_IDENTIFIER: $(AppIdentifierPrefix)$(BASE_BUNDLE_IDENTIFIER)
|
KEYCHAIN_ACCESS_GROUP_IDENTIFIER: $(AppIdentifierPrefix)$(BASE_BUNDLE_IDENTIFIER)
|
||||||
MARKETING_VERSION: 1.0.25
|
MARKETING_VERSION: 1.1.0
|
||||||
CURRENT_PROJECT_VERSION: 1
|
CURRENT_PROJECT_VERSION: 1
|
||||||
DEVELOPMENT_TEAM: 7J4U792NQT
|
DEVELOPMENT_TEAM: 7J4U792NQT
|
||||||
|
|
||||||
@@ -42,7 +42,7 @@ include:
|
|||||||
packages:
|
packages:
|
||||||
MatrixRustSDK:
|
MatrixRustSDK:
|
||||||
url: https://github.com/matrix-org/matrix-rust-components-swift
|
url: https://github.com/matrix-org/matrix-rust-components-swift
|
||||||
exactVersion: 1.0.49-alpha
|
exactVersion: 1.0.50-alpha
|
||||||
# path: ../matrix-rust-sdk
|
# path: ../matrix-rust-sdk
|
||||||
DesignKit:
|
DesignKit:
|
||||||
path: DesignKit
|
path: DesignKit
|
||||||
|
|||||||
Reference in New Issue
Block a user