diff --git a/CHANGELOG.md b/CHANGELOG.md index de025ffc..bd991747 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,3 +1,45 @@ +## 3.0.0, May 3, 2023 +You can find the full changelog [here](https://developer.onewelcome.com/flutter/plugin/v2-x) and an overview containing the upgrade instructions [here](https://developer.onewelcome.com/flutter/plugin/v2-0). + +[iOS] Wrapper SDK now uses the latest OneWelcome iOS native SDK 12.2.2 + +* Events are now propagated using Streams and have been renamed to more accurately describe their purpose. +* Removed the following events + - eventOther + - openPinAuthenticator + - eventError +* startApplication now no longer requires a OneginiListener parameter. +* All BuildContext requirements from functions have been removed. +* Resource requests now allow absolute paths. +* Allow for Resource Requests to other resource servers than the one in the tokenserver config file, this is only possible if the server has a correct certificate. +* Updated several parameters and return types of functions. +* Functions are now fully typesafe and nullsafe due to the use of [Pigeon](https://pub.dev/packages/pigeon) internally. +* Updates several functions to no longer return a boolean status but instead resolve/reject. + - setPreferredAuthenticator + - deregisterBiometricAuthenticator + - logout + - authenticateDevice + - validatePinWithPolicy + - authenticateUserImplicitly + - deregisterUser +* submitSuccessAction and submitErrorAction for custom registration no longer require an identity provider id. +* getAppToWebSingleSignOn now returns the actual error code instead of a general error when failing. +* OneginiPinRegistrationCallback.acceptAuthenticationRequest No longer takes a map as a second argument. +* Renamed several resourceRequest functions and added a generic requestResource which takes a type as extra argument. +* Reworked error codes and added constants for all errors(wrapper and native) in lib/errors/error_codes.dart +* Reworked mobileAuthWithOtp. +* Reworked authentication + - Removed getRegisteredAuthenticators + - Removed getAllAuthenticators + - Removed registerAuthenticator + - Added deregisterBiometricAuthenticator + - Added registerBiometricAuthenticator + - Added getBiometricAuthenticator + - Added getPreferredAuthenticator + - Changed setPreferredAuthenticator + - Changed authenticateUser +* Allow sdk <4.0.0 + ## 2.0.1, March 2, 2023 Updated the README diff --git a/README.md b/README.md index 487ffd3e..8a8b83c1 100644 --- a/README.md +++ b/README.md @@ -6,7 +6,7 @@ in pubspec.yaml add this: dependencies: - onegini: 2.0.1 + onegini: 3.0.0 `flutter clean` diff --git a/example/lib/screens/user_screen.dart b/example/lib/screens/user_screen.dart index bae4b2cc..4a2f15c2 100644 --- a/example/lib/screens/user_screen.dart +++ b/example/lib/screens/user_screen.dart @@ -227,16 +227,14 @@ class _UserScreenState extends State with RouteAware { ), body: _children[_currentIndex], drawer: Drawer( - child: Column( + child: ListView( children: [ DrawerHeader( - child: Container(), - ), - ListTile( - title: Text("ProfileId: ${profileId}"), - leading: Icon(Icons.person), + child: ListTile( + title: Text("ProfileId: ${profileId}"), + leading: Icon(Icons.person), + ), ), - Divider(), ListTile( title: Text("Authenticators"), leading: Icon(Icons.lock_rounded), diff --git a/ios/Classes/NativeBridge/ModuleExtensions/OneginiModuleSwift+Auth.swift b/ios/Classes/NativeBridge/ModuleExtensions/OneginiModuleSwift+Auth.swift index 3daaf9a7..512fff47 100644 --- a/ios/Classes/NativeBridge/ModuleExtensions/OneginiModuleSwift+Auth.swift +++ b/ios/Classes/NativeBridge/ModuleExtensions/OneginiModuleSwift+Auth.swift @@ -38,7 +38,7 @@ extension OneginiModuleSwift { completion(.failure(SdkError(.notFoundUserProfile).flutterError())) return } - let authenticator = SharedUserClient.instance.authenticators(.all, for: profile).first(where: { $0.type == authenticatorType }) + let authenticator = SharedUserClient.instance.authenticators(.registered, for: profile).first(where: { $0.type == authenticatorType }) bridgeConnector.toLoginHandler.authenticateUser(profile, authenticator: authenticator) { result in completion(result) diff --git a/pubspec.yaml b/pubspec.yaml index 69409ca8..79ec54e5 100644 --- a/pubspec.yaml +++ b/pubspec.yaml @@ -1,6 +1,6 @@ name: onegini description: The Onegini Flutter Plugin is a plugin that allows you to utilize the Onegini Mobile SDKs in your Flutter applications. -version: 2.0.1 +version: 3.0.0 homepage: https://www.onegini.com environment: