diff --git a/CHANGELOG.md b/CHANGELOG.md index a2ecc499..f96169b4 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,9 @@ # CHANGELOG +## 2.1.2 + +* fix: Expose keyRingSize/discardFrameWhenCryptorNotReady parameters for KeyProvider + ## 2.1.1 * update to package:web (#484) diff --git a/ios/livekit_client.podspec b/ios/livekit_client.podspec index 01e09f3c..78bb6aa4 100644 --- a/ios/livekit_client.podspec +++ b/ios/livekit_client.podspec @@ -1,6 +1,6 @@ Pod::Spec.new do |s| s.name = 'livekit_client' - s.version = '2.1.1' + s.version = '2.1.2' s.summary = 'Open source platform for real-time audio and video.' s.description = 'Open source platform for real-time audio and video.' s.homepage = 'https://livekit.io/' diff --git a/lib/src/e2ee/key_provider.dart b/lib/src/e2ee/key_provider.dart index a2652c00..0c971d56 100644 --- a/lib/src/e2ee/key_provider.dart +++ b/lib/src/e2ee/key_provider.dart @@ -23,6 +23,8 @@ const defaultRatchetSalt = 'LKFrameEncryptionKey'; const defaultMagicBytes = 'LK-ROCKS'; const defaultRatchetWindowSize = 16; const defaultFailureTolerance = -1; +const defaultKeyRingSize = 16; +const defaultDiscardFrameWhenCryptorNotReady = false; class KeyInfo { final String participantId; @@ -70,16 +72,20 @@ class BaseKeyProvider implements KeyProvider { String? uncryptedMagicBytes, int? ratchetWindowSize, int? failureTolerance, + int? keyRingSize, + bool? discardFrameWhenCryptorNotReady, }) async { rtc.KeyProviderOptions options = rtc.KeyProviderOptions( - sharedKey: sharedKey, - ratchetSalt: - Uint8List.fromList((ratchetSalt ?? defaultRatchetSalt).codeUnits), - ratchetWindowSize: ratchetWindowSize ?? defaultRatchetWindowSize, - uncryptedMagicBytes: Uint8List.fromList( - (uncryptedMagicBytes ?? defaultMagicBytes).codeUnits), - failureTolerance: failureTolerance ?? defaultFailureTolerance, - ); + sharedKey: sharedKey, + ratchetSalt: + Uint8List.fromList((ratchetSalt ?? defaultRatchetSalt).codeUnits), + ratchetWindowSize: ratchetWindowSize ?? defaultRatchetWindowSize, + uncryptedMagicBytes: Uint8List.fromList( + (uncryptedMagicBytes ?? defaultMagicBytes).codeUnits), + failureTolerance: failureTolerance ?? defaultFailureTolerance, + keyRingSize: keyRingSize ?? defaultKeyRingSize, + discardFrameWhenCryptorNotReady: + defaultDiscardFrameWhenCryptorNotReady); final keyProvider = await rtc.frameCryptorFactory.createDefaultKeyProvider(options); return BaseKeyProvider(keyProvider, options); diff --git a/lib/src/livekit.dart b/lib/src/livekit.dart index a5cfbbb9..3ca43d21 100644 --- a/lib/src/livekit.dart +++ b/lib/src/livekit.dart @@ -15,5 +15,5 @@ /// Main entry point to connect to a room. /// {@category Room} class LiveKitClient { - static const version = '2.1.1'; + static const version = '2.1.2'; } diff --git a/macos/livekit_client.podspec b/macos/livekit_client.podspec index 33cee714..4070935e 100644 --- a/macos/livekit_client.podspec +++ b/macos/livekit_client.podspec @@ -1,6 +1,6 @@ Pod::Spec.new do |s| s.name = 'livekit_client' - s.version = '2.1.1' + s.version = '2.1.2' s.summary = 'Open source platform for real-time audio and video.' s.description = 'Open source platform for real-time audio and video.' s.homepage = 'https://livekit.io/' diff --git a/pubspec.yaml b/pubspec.yaml index d541a6bd..25902f39 100644 --- a/pubspec.yaml +++ b/pubspec.yaml @@ -15,7 +15,7 @@ name: livekit_client description: Flutter Client SDK for LiveKit. Build real-time video and audio into your apps. Supports iOS, Android, and Web. -version: 2.1.1 +version: 2.1.2 homepage: https://github.com/livekit/client-sdk-flutter environment: