diff --git a/CHANGES.md b/CHANGES.md index d5664364a5..b58fd2f4a2 100644 --- a/CHANGES.md +++ b/CHANGES.md @@ -1,3 +1,10 @@ +## Changes in 1.11.39 (2026-06-23) + +🙌 Improvements + +- Reinstate the mandatory verification banner. ([#8023](https://github.com/element-hq/element-ios/issues/8023)) + + ## Changes in 1.11.38 (2026-05-27) 🐛 Bugfixes diff --git a/Config/AppVersion.xcconfig b/Config/AppVersion.xcconfig index dcf8b4546d..6f38ad26d2 100644 --- a/Config/AppVersion.xcconfig +++ b/Config/AppVersion.xcconfig @@ -15,5 +15,5 @@ // // Version -MARKETING_VERSION = 1.11.38 -CURRENT_PROJECT_VERSION = 1.11.38 +MARKETING_VERSION = 1.11.39 +CURRENT_PROJECT_VERSION = 1.11.39 diff --git a/Riot/Assets/et.lproj/Vector.strings b/Riot/Assets/et.lproj/Vector.strings index 15ce5916f4..fbb938eb6f 100644 --- a/Riot/Assets/et.lproj/Vector.strings +++ b/Riot/Assets/et.lproj/Vector.strings @@ -2738,3 +2738,7 @@ "room_member_power_level_owner_in" = "„%@“ jututoa omanik"; "room_member_power_level_short_owner" = "Omanik"; "room_participants_leave_not_allowed_for_last_owner_msg" = "Kuna oled jututoa ainus omanik, siis sa ei saa siit lahkuda."; +"verification_required_banner_title" = "Verifitseeri see seade"; +"verification_required_banner_verify_button" = "Verifitseeri kohe"; +"verification_required_banner_description" = "Alates 2026. aasta oktoobrist ei saa verifitseerimata seadmed sõnumeid saata ega neid vastu võtta"; +"verification_required_banner_learn_more" = "Lisateave"; diff --git a/Riot/Assets/lv.lproj/Vector.strings b/Riot/Assets/lv.lproj/Vector.strings index ef38ead5f4..3aaa9b2f9d 100644 --- a/Riot/Assets/lv.lproj/Vector.strings +++ b/Riot/Assets/lv.lproj/Vector.strings @@ -48,7 +48,6 @@ // MARK: - MatrixKit - "matrix" = "Matrix"; // Login Screen "login_create_account" = "Izveidot kontu:"; @@ -140,8 +139,8 @@ // Action "no" = "Nē"; -"login_error_resource_limit_exceeded_contact_button" = "Sazinieties ar administratoru"; -"login_error_resource_limit_exceeded_message_contact" = "\n\nLai turpinātu lietot šo pakalpojumu, lūdzu, sazinieties ar savu pakalpojuma administratoru."; +"login_error_resource_limit_exceeded_contact_button" = "Sazināties ar pārvaldītāju"; +"login_error_resource_limit_exceeded_message_contact" = "\n\nLūgums sazināties ar pakalpojuma pārvaldītāju, lai turpinātu izmantot pakalpojumu."; "login_error_resource_limit_exceeded_message_monthly_active_user" = "Šis mājas serveris ir sasniedzis ikmēneša aktīvo lietotāju limitu."; "login_error_resource_limit_exceeded_message_default" = "Šis mājas serveris ir sasniedzis vienu no savu resursu limitiem."; "login_desktop_device" = "Dators"; diff --git a/Riot/Assets/nl.lproj/Vector.strings b/Riot/Assets/nl.lproj/Vector.strings index 55afcd7240..a15ff8798d 100644 --- a/Riot/Assets/nl.lproj/Vector.strings +++ b/Riot/Assets/nl.lproj/Vector.strings @@ -2806,3 +2806,4 @@ "verification_required_banner_description" = "Vanaf oktober 2026 kunnen niet-geverifieerde apparaten geen berichten meer verzenden en ontvangen."; "verification_required_banner_learn_more" = "Meer informatie"; "verification_required_banner_verify_button" = "Nu verifiëren"; +"accessibility_selected" = "seleccionat"; diff --git a/Riot/Assets/sq.lproj/Vector.strings b/Riot/Assets/sq.lproj/Vector.strings index 9db8859054..1a83898552 100644 --- a/Riot/Assets/sq.lproj/Vector.strings +++ b/Riot/Assets/sq.lproj/Vector.strings @@ -2775,7 +2775,7 @@ "sunset_download_banner_learn_more" = "Mësoni më tepër"; "room_member_power_level_short_owner" = "I zoti"; "room_member_power_level_owner_in" = "I zoti i %@"; -"verification_required_banner_description" = "Duke filluar nga prilli i 2026, pajisjet e paverifikuara s’do të jenë në gjendje të dërgojnë dhe marrin mesazhe"; +"verification_required_banner_description" = "Duke filluar nga tetori i 2026,-s pajisjet e paverifikuara s’do të jenë në gjendje të dërgojnë dhe marrin mesazhe"; "verification_required_banner_learn_more" = "Mësoni më tepër"; "room_participants_leave_not_allowed_for_last_owner_msg" = "S’mund ta braktisni dhomën, ngaqë jeni i zoti i vetëm i saj."; "verification_required_banner_verify_button" = "Verifikojeni tani"; diff --git a/Riot/Modules/Application/LegacyAppDelegate.m b/Riot/Modules/Application/LegacyAppDelegate.m index 3851deb853..b27765ad5c 100644 --- a/Riot/Modules/Application/LegacyAppDelegate.m +++ b/Riot/Modules/Application/LegacyAppDelegate.m @@ -3376,8 +3376,7 @@ - (void)checkCrossSigningForSession:(MXSession*)mxSession case MXCrossSigningStateCrossSigningExists: MXLogDebug(@"[AppDelegate] handleAppState: presentVerifyCurrentSessionAlertIfNeededWithSession"); [self.masterTabBarController presentVerifyCurrentSessionAlertIfNeededWithSession:mxSession]; - // Temporarily disabled until we have a way to reset from the verification screen. - // [self.masterTabBarController presentVerificationRequiredBannerWithSession:mxSession]; + [self.masterTabBarController presentVerificationRequiredBannerWithSession:mxSession]; break; case MXCrossSigningStateCanCrossSign: MXLogDebug(@"[AppDelegate] handleAppState: presentReviewUnverifiedSessionsAlertIfNeededWithSession"); diff --git a/Riot/Modules/Home/AllChats/AllChatsViewController.swift b/Riot/Modules/Home/AllChats/AllChatsViewController.swift index f47e9622bb..ca50a99404 100644 --- a/Riot/Modules/Home/AllChats/AllChatsViewController.swift +++ b/Riot/Modules/Home/AllChats/AllChatsViewController.swift @@ -849,7 +849,7 @@ extension AllChatsViewController: SplitViewMasterViewControllerProtocol { } func presentVerificationRequiredBanner(with session: MXSession) { - guard bannerView == nil else { + guard bannerView == nil, VerificationRequiredBannerChecker().canShowBanner(for: session) else { return } diff --git a/Riot/Modules/Home/VerificationRequiredBanner/VerificationRequiredBannerChecker.swift b/Riot/Modules/Home/VerificationRequiredBanner/VerificationRequiredBannerChecker.swift new file mode 100644 index 0000000000..7670558302 --- /dev/null +++ b/Riot/Modules/Home/VerificationRequiredBanner/VerificationRequiredBannerChecker.swift @@ -0,0 +1,22 @@ +// +// Copyright 2022-2024 New Vector Ltd. +// +// SPDX-License-Identifier: AGPL-3.0-only OR LicenseRef-Element-Commercial +// Please see LICENSE files in the repository root for full details. +// + +import Foundation +import CryptoKit + +struct VerificationRequiredBannerChecker { + func canShowBanner(for session: MXSession) -> Bool { + guard let userID = session.myUserId, + let serverName = MXTools.serverName(inMatrixIdentifier: userID), + let data = serverName.components(separatedBy: ".").suffix(2).joined(separator: ".").data(using: .utf8) else { + return true + } + + let hash = SHA256.hash(data: data).map { String(format: "%02x", $0) }.joined() + return hash != "9e6d1ca3e739dd3f879b8046af783402a34d247f879dfa1b531edbd56a56c1a6" + } +} diff --git a/RiotTests/VerificationRequiredBannerCheckerTests.swift b/RiotTests/VerificationRequiredBannerCheckerTests.swift new file mode 100644 index 0000000000..ad70f19df8 --- /dev/null +++ b/RiotTests/VerificationRequiredBannerCheckerTests.swift @@ -0,0 +1,25 @@ +// +// Copyright 2026 Element Creations Ltd. +// +// SPDX-License-Identifier: AGPL-3.0-only OR LicenseRef-Element-Commercial +// Please see LICENSE files in the repository root for full details. +// + +import XCTest + +@testable import Element + +class VerificationRequiredBannerCheckerTests: XCTestCase { + private let checker = VerificationRequiredBannerChecker() + + func testCanShowBanner() { + XCTAssertTrue(checker.canShowBanner(for: makeSession(userID: "@user:example.com"))) + XCTAssertTrue(checker.canShowBanner(for: makeSession(userID: "@user:matrix.org"))) + } + + private func makeSession(userID: String) -> MXSession! { + MXSession(matrixRestClient: .init(credentials: .init(homeServer: "", + userId: userID, + accessToken: ""))) + } +}