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

Update iOS SDK to use Crypto Sdk for content scanner #7843

Merged
merged 3 commits into from
Sep 16, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
36 changes: 18 additions & 18 deletions Podfile.lock
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ PODS:
- GBDeviceInfo/Core (= 7.1.0)
- GBDeviceInfo/Core (7.1.0)
- GZIP (1.3.2)
- Introspect (0.11.0)
- Introspect (0.12.0)
- JitsiMeetSDKLite (8.1.2-lite):
- JitsiWebRTC (~> 111.0)
- JitsiWebRTC (111.0.2)
Expand All @@ -39,20 +39,20 @@ PODS:
- LoggerAPI (1.9.200):
- Logging (~> 1.1)
- Logging (1.4.0)
- MatrixSDK (0.27.11):
- MatrixSDK/Core (= 0.27.11)
- MatrixSDK/Core (0.27.11):
- MatrixSDK (0.27.13):
- MatrixSDK/Core (= 0.27.13)
- MatrixSDK/Core (0.27.13):
- AFNetworking (~> 4.0.0)
- GZIP (~> 1.3.0)
- libbase58 (~> 0.1.4)
- MatrixSDKCrypto (= 0.4.2)
- MatrixSDKCrypto (= 0.4.3)
- OLMKit (~> 3.2.5)
- Realm (= 10.27.0)
- SwiftyBeaver (= 1.9.5)
- MatrixSDK/JingleCallStack (0.27.11):
- MatrixSDK/JingleCallStack (0.27.13):
- JitsiMeetSDKLite (= 8.1.2-lite)
- MatrixSDK/Core
- MatrixSDKCrypto (0.4.2)
- MatrixSDKCrypto (0.4.3)
- OLMKit (3.2.12):
- OLMKit/olmc (= 3.2.12)
- OLMKit/olmcpp (= 3.2.12)
Expand All @@ -72,15 +72,15 @@ PODS:
- Sentry/Core (7.15.0)
- SideMenu (6.5.0)
- SwiftBase32 (0.9.0)
- SwiftFormat/CLI (0.50.2)
- SwiftGen (6.6.2)
- SwiftFormat/CLI (0.54.5)
- SwiftGen (6.6.3)
- SwiftJWT (3.6.200):
- BlueCryptor (~> 1.0)
- BlueECC (~> 1.1)
- BlueRSA (~> 1.0)
- KituraContracts (~> 1.2)
- LoggerAPI (~> 1.7)
- SwiftLint (0.49.1)
- SwiftLint (0.57.0)
- SwiftyBeaver (1.9.5)
- UICollectionViewLeftAlignedLayout (1.0.2)
- UICollectionViewRightAlignedLayout (0.0.3)
Expand Down Expand Up @@ -177,7 +177,7 @@ SPEC CHECKSUMS:
FlowCommoniOS: ca92071ab526dc89905495a37844fd7e78d1a7f2
GBDeviceInfo: 5d62fa85bdcce3ed288d83c28789adf1173e4376
GZIP: 3c0abf794bfce8c7cb34ea05a1837752416c8868
Introspect: 4cc1e4c34dd016540c8d86a591c231c09dafbee3
Introspect: b66b675de8a85d9ef832f3a710d8e3c7db186884
JitsiMeetSDKLite: 895213158cf62342069a10634a41d2f1c00057f7
JitsiWebRTC: 80f62908fcf2a1160e0d14b584323fb6e6be630b
KeychainAccess: c0c4f7f38f6fc7bbe58f5702e25f7bd2f65abf51
Expand All @@ -187,26 +187,26 @@ SPEC CHECKSUMS:
libPhoneNumber-iOS: 0a32a9525cf8744fe02c5206eb30d571e38f7d75
LoggerAPI: ad9c4a6f1e32f518fdb43a1347ac14d765ab5e3d
Logging: beeb016c9c80cf77042d62e83495816847ef108b
MatrixSDK: 7c29e5cc8934cfc1f81f83fcfa17cd652612086d
MatrixSDKCrypto: 736069ee0a5ec12852ab3498bf2242acecc443fc
MatrixSDK: 1dae186c839eb145974fc1fc127ec903de60a297
MatrixSDKCrypto: 27bee960e0e8b3a3039f3f3e93dd2ec88299c77e
OLMKit: da115f16582e47626616874e20f7bb92222c7a51
ReadMoreTextView: 19147adf93abce6d7271e14031a00303fe28720d
Realm: 9ca328bd7e700cc19703799785e37f77d1a130f2
Reusable: 6bae6a5e8aa793c9c441db0213c863a64bce9136
Sentry: 63ca44f5e0c8cea0ee5a07686b02e56104f41ef7
SideMenu: f583187d21c5b1dd04c72002be544b555a2627a2
SwiftBase32: 9399c25a80666dc66b51e10076bf591e3bbb8f17
SwiftFormat: 710117321c55c82675c0dc03055128efbb13c38f
SwiftGen: 1366a7f71aeef49954ca5a63ba4bef6b0f24138c
SwiftFormat: 543a7b1ab4a6ce2d88bd5616a17903446ca3dc5c
SwiftGen: 4993cbf71cbc4886f775e26f8d5c3a1188ec9f99
SwiftJWT: 88c412708f58c169d431d344c87bc79a87c830ae
SwiftLint: 32ee33ded0636d0905ef6911b2b67bbaeeedafa5
SwiftLint: eb47480d47c982481592c195c221d11013a679cc
SwiftyBeaver: 84069991dd5dca07d7069100985badaca7f0ce82
UICollectionViewLeftAlignedLayout: 830bf6fa5bab9f9b464f62e3384f9d2e00b3c0f6
UICollectionViewRightAlignedLayout: 823eef8c567eba4a44c21bc2ffcb0d0d5f361e2d
WeakDictionary: 8cd038acd77e5d54ca4ebaec3d20853d732b45e0
zxcvbn-ios: fef98b7c80f1512ff0eec47ac1fa399fc00f7e3c
ZXingObjC: 8898711ab495761b2dbbdec76d90164a6d7e14c5

PODFILE CHECKSUM: 7e14a7efb021fca69b3ffc2ffbe5fe632e6df7ea
PODFILE CHECKSUM: fb3e1c62f9e35a9bdbafce743664bf4f620af028

COCOAPODS: 1.14.3
COCOAPODS: 1.15.2
2 changes: 1 addition & 1 deletion Riot/Modules/Pills/PillAttachmentView.swift
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
import UIKit

/// Base view class for mention Pills.
@available (iOS 15.0, *)
@available(iOS 15.0, *)
@objcMembers
class PillAttachmentView: UIView {
// MARK: - Internal Structs
Expand Down
4 changes: 2 additions & 2 deletions Riot/Modules/Pills/PillProvider.swift
Original file line number Diff line number Diff line change
Expand Up @@ -16,13 +16,13 @@

import Foundation

@available (iOS 15.0, *)
@available(iOS 15.0, *)
private enum PillAttachmentKind {
case attachment(PillTextAttachment)
case string(NSAttributedString)
}

@available (iOS 15.0, *)
@available(iOS 15.0, *)
struct PillProvider {
private let session: MXSession
private let eventFormatter: MXKEventFormatter
Expand Down
4 changes: 2 additions & 2 deletions Riot/Modules/Pills/PillTextAttachment.swift
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ import UIKit
import MatrixSDK

/// Text attachment for pills display.
@available (iOS 15.0, *)
@available(iOS 15.0, *)
@objcMembers
class PillTextAttachment: NSTextAttachment {
// MARK: - Properties
Expand Down Expand Up @@ -133,7 +133,7 @@ class PillTextAttachment: NSTextAttachment {
}

// MARK: - Private
@available (iOS 15.0, *)
@available(iOS 15.0, *)
private extension PillTextAttachment {

func updateBounds() {
Expand Down
10 changes: 5 additions & 5 deletions Riot/Modules/Pills/PillTextAttachmentData.swift
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
import Foundation
import UIKit

@available (iOS 15.0, *)
@available(iOS 15.0, *)
struct PillAssetColor: Codable {
var red: CGFloat = 0.0, green: CGFloat = 0.0, blue: CGFloat = 0.0, alpha: CGFloat = 0.0

Expand All @@ -30,23 +30,23 @@ struct PillAssetColor: Codable {
}
}

@available (iOS 15.0, *)
@available(iOS 15.0, *)
struct PillAssetParameter: Codable {
var tintColor: PillAssetColor?
var backgroundColor: PillAssetColor?
var rawRenderingMode: Int = UIImage.RenderingMode.automatic.rawValue
var padding: CGFloat = 2.0
}

@available (iOS 15.0, *)
@available(iOS 15.0, *)
enum PillTextAttachmentItem: Codable {
case text(String)
case avatar(url: String?, string: String?, matrixId: String)
case spaceAvatar(url: String?, string: String?, matrixId: String)
case asset(named: String, parameters: PillAssetParameter)
}

@available (iOS 15.0, *)
@available(iOS 15.0, *)
extension PillTextAttachmentItem {
var string: String? {
switch self {
Expand All @@ -59,7 +59,7 @@ extension PillTextAttachmentItem {
}

/// Data associated with a Pill text attachment.
@available (iOS 15.0, *)
@available(iOS 15.0, *)
struct PillTextAttachmentData: Codable {
// MARK: - Properties
/// Pill type
Expand Down
4 changes: 2 additions & 2 deletions Riot/Modules/Pills/PillType.swift
Original file line number Diff line number Diff line change
Expand Up @@ -16,14 +16,14 @@

import Foundation

@available (iOS 15.0, *)
@available(iOS 15.0, *)
enum PillType: Codable {
case user(userId: String) /// userId
case room(roomId: String) /// roomId
case message(roomId: String, eventId: String) // roomId, eventId
}

@available (iOS 15.0, *)
@available(iOS 15.0, *)
extension PillType {
private static var regexPermalinkTarget: NSRegularExpression? = {
let clientBaseUrl = BuildSettings.clientPermalinkBaseUrl ?? kMXMatrixDotToUrl
Expand Down
4 changes: 2 additions & 2 deletions Riot/Modules/Pills/PillsFormatter.swift
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ import Foundation
import UIKit

/// Provides utilities funcs to handle Pills inside attributed strings.
@available (iOS 15.0, *)
@available(iOS 15.0, *)
@objcMembers
class PillsFormatter: NSObject {
// MARK: - Internal Properties
Expand Down Expand Up @@ -214,7 +214,7 @@ class PillsFormatter: NSObject {
}

// MARK: - Private Methods
@available (iOS 15.0, *)
@available(iOS 15.0, *)
extension PillsFormatter {
struct MarkdownLinkResult: Equatable {
let url: URL
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ class VoiceMessagePlaybackView: UIView, NibLoadable, Themable {
@IBOutlet private var playButton: UIButton!
@IBOutlet private var elapsedTimeLabel: UILabel!
@IBOutlet private var waveformContainerView: UIView!
@IBOutlet private (set)var stackViewTrailingContraint: NSLayoutConstraint!
@IBOutlet private(set) var stackViewTrailingContraint: NSLayoutConstraint!

private var longPressGestureRecognizer: UILongPressGestureRecognizer!
private var panGestureRecognizer: UIPanGestureRecognizer!
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -92,7 +92,7 @@ final class SettingsIdentityServerViewModel: SettingsIdentityServerViewModelType

private func checkCanAddIdentityServer(newIdentityServer: String,
viewStateUpdate: @escaping (SettingsIdentityServerViewState) -> Void,
canAddcompletion: @escaping(() -> Void)) {
canAddcompletion: @escaping (() -> Void)) {
viewStateUpdate(.loading)

self.checkIdentityServerValidity(identityServer: newIdentityServer) { (identityServerValidityResponse) in
Expand Down Expand Up @@ -228,7 +228,7 @@ final class SettingsIdentityServerViewModel: SettingsIdentityServerViewModelType

private func checkCanDisconnectIdentityServer(identityServer: String,
viewStateUpdate: @escaping (SettingsIdentityServerViewState) -> Void,
canDisconnectCompletion: @escaping(() -> Void)) {
canDisconnectCompletion: @escaping (() -> Void)) {
self.update(viewState: .loading)

self.checkExistingDataOnIdentityServer { (response) in
Expand Down
Loading