Skip to content

Commit 1f0a619

Browse files
Release 3.1.0
1 parent 356e0c8 commit 1f0a619

File tree

17 files changed

+323
-49
lines changed

17 files changed

+323
-49
lines changed

CHANGELOG.md

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,24 @@
11
# iProov Biometrics Flutter SDK
22

3+
## 3.1.0
4+
5+
iProov SDK Biometrics Flutter SDK v3.1.0 includes bug fixes
6+
7+
Please consult the [Upgrade Guide](https://github.com/iProov/flutter/wiki/Upgrade-Guide#upgrading-to-v30) for detailed instructions on how to upgrade to this new version.
8+
9+
### Flutter
10+
11+
* Fix how `feedbackCode`, `reason` and `frame` values are returned by `IProovEventFailure`, and value `frame` by `IProovEventSucces` in the Android side.
12+
13+
### iOS
14+
15+
* Upgraded SDK to [v10.1.2](https://github.com/iProov/ios/releases/tag/10.1.2).
16+
17+
### Android
18+
19+
* Upgraded SDK to [v8.3.0](https://github.com/iProov/android/releases/tag/v8.3.0).
20+
21+
322
## 3.0.0
423

524
iProov SDK Biometrics Flutter SDK v3.0.0 is a major update which includes a number of improvements and breaking changes.

LICENSE.md

Lines changed: 206 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,206 @@
1+
iproov_flutter
2+
3+
- Please refer to the iOS Biometrics SDK license here: https://github.com/iProov/ios/blob/master/LICENSE.md.
4+
5+
- Please refer to the Android Biometrics SDK license here: https://github.com/iProov/android/blob/master/LICENSE.md.
6+
7+
--------------------------------------------------------------------------------
8+
API Client and Sample Code
9+
10+
Copyright 2021 iProov Limited
11+
12+
Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met:
13+
14+
1. Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer.
15+
16+
2. Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution.
17+
18+
3. Neither the name of the copyright holder nor the names of its contributors may be used to endorse or promote products derived from this software without specific prior written permission.
19+
20+
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
21+
22+
--------------------------------------------------------------------------------
23+
image
24+
25+
Copyright 2013 Brendan Duncan
26+
27+
Licensed under the Apache License, Version 2.0 (the "License");
28+
you may not use this file except in compliance with the License.
29+
You may obtain a copy of the License at
30+
31+
http://www.apache.org/licenses/LICENSE-2.0
32+
33+
Unless required by applicable law or agreed to in writing, software
34+
distributed under the License is distributed on an "AS IS" BASIS,
35+
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
36+
See the License for the specific language governing permissions and
37+
limitations under the License.
38+
39+
40+
41+
Parts of the Image library were ported from the following sources:
42+
43+
==============================================================================
44+
45+
The JPEG encoder/decoder code is derived from the following:
46+
https://github.com/notmasteryet/jpgjs
47+
Copyright (C) 2011 notmasteryet
48+
49+
Contributors: Yury Delendik <[email protected]>
50+
Brendan Dahl <[email protected]>
51+
52+
Licensed under the Apache License, Version 2.0 (the "License");
53+
you may not use this file except in compliance with the License.
54+
You may obtain a copy of the License at
55+
56+
http://www.apache.org/licenses/LICENSE-2.0
57+
58+
Unless required by applicable law or agreed to in writing, software
59+
distributed under the License is distributed on an "AS IS" BASIS,
60+
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
61+
See the License for the specific language governing permissions and
62+
limitations under the License.
63+
64+
==============================================================================
65+
66+
The WebP encoder/decoder code is derived from the following:
67+
http://git.chromium.org/gitweb/?p=webm/libwebp.git
68+
Copyright (c) 2010, Google Inc. All rights reserved.
69+
70+
Redistribution and use in source and binary forms, with or without
71+
modification, are permitted provided that the following conditions are
72+
met:
73+
74+
* Redistributions of source code must retain the above copyright
75+
notice, this list of conditions and the following disclaimer.
76+
77+
* Redistributions in binary form must reproduce the above copyright
78+
notice, this list of conditions and the following disclaimer in
79+
the documentation and/or other materials provided with the
80+
distribution.
81+
82+
* Neither the name of Google nor the names of its contributors may
83+
be used to endorse or promote products derived from this software
84+
without specific prior written permission.
85+
86+
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
87+
"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
88+
LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
89+
A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
90+
HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
91+
SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
92+
LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
93+
DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
94+
THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
95+
(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
96+
OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
97+
98+
==============================================================================
99+
100+
The TIFF decoder code is derived from the following:
101+
Apache Batik
102+
http://svn.apache.org/repos/asf/xmlgraphics/batik/trunk
103+
Copyright 1999-2007 The Apache Software Foundation
104+
Licensed under the Apache License, Version 2.0 (the "License");
105+
you may not use this file except in compliance with the License.
106+
You may obtain a copy of the License at
107+
108+
http://www.apache.org/licenses/LICENSE-2.0
109+
110+
Unless required by applicable law or agreed to in writing, software
111+
distributed under the License is distributed on an "AS IS" BASIS,
112+
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
113+
See the License for the specific language governing permissions and
114+
limitations under the License.
115+
116+
==============================================================================
117+
118+
The OpenEXR decoder is derived in part from the OpenEXR library:
119+
120+
Copyright (c) 2002-2011, Industrial Light & Magic, a division of
121+
Lucasfilm Entertainment Company Ltd. All rights reserved.
122+
123+
Redistribution and use in source and binary forms, with or without
124+
modification, are permitted provided that the following conditions are met:
125+
126+
127+
Redistributions of source code must retain the above copyright notice, this
128+
list of conditions and the following disclaimer.
129+
Redistributions in binary form must reproduce the above copyright notice, this
130+
list of conditions and the following disclaimer in the documentation and/or
131+
other materials provided with the distribution.
132+
Neither the name of Industrial Light & Magic nor the names of its contributors
133+
may be used to endorse or promote products derived from this software without
134+
specific prior written permission.
135+
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
136+
ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
137+
WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
138+
DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR
139+
ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
140+
(INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
141+
LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
142+
ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
143+
(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
144+
SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
145+
146+
===============================================================================
147+
148+
The PVRTC compression and decompression code is ported from Jeffrey Lim's
149+
PvrTcCompressor:
150+
151+
https://bitbucket.org/jthlim/pvrtccompressor
152+
153+
Copyright © 2014, Jeffrey Lim. All Rights Reserved.
154+
155+
Redistribution and use in source and binary forms, with or without
156+
modification, are permitted provided that the following conditions are met:
157+
158+
1. Redistributions of source code must retain the above copyright notice,
159+
this list of conditions and the following disclaimer.
160+
161+
2. Redistributions in binary form must reproduce the above copyright notice,
162+
this list of conditions and the following disclaimer in the documentation
163+
and/or other materials provided with the distribution.
164+
165+
3. The name of the author may not be used to endorse or promote products
166+
derived from this software without specific prior written permission.
167+
168+
THIS SOFTWARE IS PROVIDED "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES,
169+
INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND
170+
FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR
171+
BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
172+
CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
173+
SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
174+
INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
175+
CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
176+
ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
177+
POSSIBILITY OF SUCH DAMAGE.
178+
179+
===============================================================================
180+
181+
The pvr container format decoder is derived from the QuickPVR project:
182+
QuickPVR is Copyright (C) 2010 Limbic Software, Inc.
183+
http://www.limbicsoftware.com/quickpvr.html
184+
185+
Redistribution and use in source and binary forms, with or without
186+
modification, are permitted provided that the following conditions are met:
187+
* Redistributions of source code must retain the above copyright
188+
notice, this list of conditions and the following disclaimer.
189+
* Redistributions in binary form must reproduce the above copyright
190+
notice, this list of conditions and the following disclaimer in the
191+
documentation and/or other materials provided with the distribution.
192+
* Neither the name of the Limbic Software, Inc. nor the
193+
names of its contributors may be used to endorse or promote products
194+
derived from this software without specific prior written permission.
195+
196+
THIS SOFTWARE IS PROVIDED BY LIMBIC SOFTWARE, INC. ''AS IS'' AND ANY
197+
EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
198+
WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
199+
DISCLAIMED. IN NO EVENT SHALL LIMBIC SOFTWARE, INC. BE LIABLE FOR ANY
200+
DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
201+
(INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
202+
LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
203+
ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
204+
(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
205+
SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
206+

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@ Add the following to your project's `pubspec.yml` file:
3535

3636
```yaml
3737
dependencies:
38-
iproov_flutter: ^3.0.0
38+
iproov_flutter: ^3.1.0
3939
```
4040
4141
You can then install it with:

android/.idea/gradle.xml

Lines changed: 1 addition & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

android/.idea/jarRepositories.xml

Lines changed: 5 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

android/.idea/modules.xml

Lines changed: 3 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

android/build.gradle

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -41,5 +41,5 @@ android {
4141

4242
dependencies {
4343
implementation "org.jetbrains.kotlin:kotlin-stdlib-jdk7:$kotlin_version"
44-
implementation "com.iproov.sdk:iproov:8.1.0"
44+
implementation "com.iproov.sdk:iproov:8.3.0"
4545
}

android/gradle/wrapper/gradle-wrapper.properties

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,4 +2,4 @@ distributionBase=GRADLE_USER_HOME
22
distributionPath=wrapper/dists
33
zipStoreBase=GRADLE_USER_HOME
44
zipStorePath=wrapper/dists
5-
distributionUrl=https\://services.gradle.org/distributions/gradle-6.5-all.zip
5+
distributionUrl=https\://services.gradle.org/distributions/gradle-6.7.1-all.zip

android/src/main/kotlin/com/iproov/sdk/IProovSDKPlugin.kt

Lines changed: 33 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -1,25 +1,17 @@
11
package com.iproov.sdk
22

33
import android.content.Context
4+
import android.graphics.Bitmap
45
import com.iproov.sdk.bridge.OptionsBridge
5-
import com.iproov.sdk.core.exception.CameraException
6-
import com.iproov.sdk.core.exception.CameraPermissionException
7-
import com.iproov.sdk.core.exception.CaptureAlreadyActiveException
8-
import com.iproov.sdk.core.exception.FaceDetectorException
9-
import com.iproov.sdk.core.exception.IProovException
10-
import com.iproov.sdk.core.exception.InvalidOptionsException
11-
import com.iproov.sdk.core.exception.MultiWindowUnsupportedException
12-
import com.iproov.sdk.core.exception.NetworkException
13-
import com.iproov.sdk.core.exception.ServerException
14-
import com.iproov.sdk.core.exception.UnexpectedErrorException
15-
import com.iproov.sdk.core.exception.UnsupportedDeviceException
6+
import com.iproov.sdk.core.exception.*
167
import io.flutter.FlutterInjector
178
import io.flutter.embedding.engine.plugins.FlutterPlugin
189
import io.flutter.plugin.common.EventChannel
1910
import io.flutter.plugin.common.MethodCall
2011
import io.flutter.plugin.common.MethodChannel
2112
import org.json.JSONObject
22-
import java.lang.Exception
13+
import java.io.ByteArrayOutputStream
14+
2315

2416
class IProovSDKPlugin: FlutterPlugin {
2517

@@ -38,35 +30,56 @@ class IProovSDKPlugin: FlutterPlugin {
3830
private val iProovListener = object : IProovCallbackLauncher.Listener {
3931
override fun onConnecting() {
4032
eventSink?.success(hashMapOf(
41-
"event" to "connecting"
33+
"event" to "connecting"
4234
))
4335
}
4436

4537
override fun onConnected() {
4638
eventSink?.success(hashMapOf(
47-
"event" to "connected"
39+
"event" to "connected"
4840
))
4941
}
5042

5143
override fun onProcessing(progress: Double, message: String?) {
5244
eventSink?.success(hashMapOf(
53-
"event" to "processing",
54-
"progress" to progress,
55-
"message" to message
45+
"event" to "processing",
46+
"progress" to progress,
47+
"message" to message
5648
))
5749
}
5850

5951
override fun onSuccess(result: IProov.SuccessResult) {
52+
val frameArray = result.frame?.let { bmp ->
53+
val stream = ByteArrayOutputStream()
54+
bmp.compress(Bitmap.CompressFormat.PNG, 100, stream)
55+
val byteArray: ByteArray = stream.toByteArray()
56+
bmp.recycle()
57+
byteArray
58+
}
59+
6060
eventSink?.success(hashMapOf(
61-
"event" to "success"
61+
"event" to "success",
62+
"frame" to frameArray
6263
))
6364
eventSink?.endOfStream()
6465
}
6566

6667
override fun onFailure(result: IProov.FailureResult) {
68+
val context = flutterPluginBinding!!.applicationContext
69+
70+
val frameArray = result.frame?.let { bmp ->
71+
val stream = ByteArrayOutputStream()
72+
bmp.compress(Bitmap.CompressFormat.PNG, 100, stream)
73+
val byteArray: ByteArray = stream.toByteArray()
74+
bmp.recycle()
75+
byteArray
76+
}
77+
6778
eventSink?.success(hashMapOf(
68-
"event" to "failure",
69-
"reason" to result.reason.feedbackCode
79+
"event" to "failure",
80+
"feedbackCode" to result.reason.feedbackCode,
81+
"reason" to context.getString(result.reason.description),
82+
"frame" to frameArray
7083
))
7184
eventSink?.endOfStream()
7285
}

example/.gitignore

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -42,3 +42,10 @@ app.*.symbols
4242
app.*.map.json
4343

4444
.idea/workspace.xml
45+
46+
linux/flutter/generated_plugin_registrant.cc
47+
linux/flutter/generated_plugin_registrant.h
48+
linux/flutter/generated_plugins.cmake
49+
macos/Podfile
50+
macos/Flutter/GeneratedPluginRegistrant.swift
51+
macos/Flutter/ephemeral/Flutter-Generated.xcconfig

0 commit comments

Comments
 (0)