diff --git a/CHANGES.md b/CHANGES.md index 404ac4b97..ad8f78f28 100644 --- a/CHANGES.md +++ b/CHANGES.md @@ -1,3 +1,8 @@ +## Changes in 0.27.7 (2024-05-01) + +No significant changes. + + ## Changes in 0.27.6 (2024-02-07) No significant changes. diff --git a/MatrixSDK.podspec b/MatrixSDK.podspec index 84c8b1b3d..fadc44551 100644 --- a/MatrixSDK.podspec +++ b/MatrixSDK.podspec @@ -1,7 +1,7 @@ Pod::Spec.new do |s| s.name = "MatrixSDK" - s.version = "0.27.6" + s.version = "0.27.7" s.summary = "The iOS SDK to build apps compatible with Matrix (https://www.matrix.org)" s.description = <<-DESC diff --git a/MatrixSDK/Crypto/MXCrypto.h b/MatrixSDK/Crypto/MXCrypto.h index 3f12cdd45..348edddd0 100644 --- a/MatrixSDK/Crypto/MXCrypto.h +++ b/MatrixSDK/Crypto/MXCrypto.h @@ -95,6 +95,12 @@ extern NSString *const MXDeviceListDidUpdateUsersDevicesNotification; */ @property (nullable, nonatomic, readonly) NSString *deviceEd25519Key; + +/** +* The user device creation in local timestamp, milliseconds since epoch. +*/ +@property (nonatomic, readonly) UInt64 deviceCreationTs; + /** The key backup manager. */ diff --git a/MatrixSDK/Crypto/MXCrypto.m b/MatrixSDK/Crypto/MXCrypto.m index fc599496f..c75c39b8d 100644 --- a/MatrixSDK/Crypto/MXCrypto.m +++ b/MatrixSDK/Crypto/MXCrypto.m @@ -1422,6 +1422,12 @@ - (NSString *)olmVersion #endif } +- (uint64_t)deviceCreationTs +{ + // Device creation timestamp is not support in legacy crypto + return 0; +} + #pragma mark - Gossipping diff --git a/MatrixSDK/Crypto/MXCryptoV2.swift b/MatrixSDK/Crypto/MXCryptoV2.swift index 2e5c642b7..adea4ac92 100644 --- a/MatrixSDK/Crypto/MXCryptoV2.swift +++ b/MatrixSDK/Crypto/MXCryptoV2.swift @@ -56,6 +56,11 @@ class MXCryptoV2: NSObject, MXCrypto { return machine.deviceEd25519Key } + var deviceCreationTs: UInt64 { + // own device always exists + return machine.device(userId: machine.userId, deviceId: machine.deviceId)!.firstTimeSeenTs + } + let backup: MXKeyBackup? let keyVerificationManager: MXKeyVerificationManager let crossSigning: MXCrossSigning diff --git a/MatrixSDK/MatrixSDKVersion.m b/MatrixSDK/MatrixSDKVersion.m index 3f16e20dc..5a4d405a6 100644 --- a/MatrixSDK/MatrixSDKVersion.m +++ b/MatrixSDK/MatrixSDKVersion.m @@ -16,4 +16,4 @@ #import -NSString *const MatrixSDKVersion = @"0.27.6"; +NSString *const MatrixSDKVersion = @"0.27.7";