Open ifbbprochris opened 3 years ago
+1 I have the same problem. Samsung M20 supported FaceId a couple of days ago - updated plugin and no longer recognizes face
+1 I have the same problem with Samsung galaxy a8
+1 I'm using android 10, and I register my face ID but when I invoke Fingerprint.isAvailable it returns the error BIOMETRIC_NOT_ENROLLED. and when I enroll my fingerprint it return success which means that the plugin doesn't support faceId authentication .
Is there any update on this issue ?
Is there any update on this issue?
Tried to adopt this plugin in my code. My testing devices are the following. Both have fingerprint scanner and face recognition. Both have face screen unlock turned on, and it works well for this purpose.
Plugin utilizes standard Android API calls (from AndroidX support library):
BiometricManager#canAuthenticate()
](https://developer.android.com/reference/androidx/biometric/BiometricManager#canAuthenticate()) to determine if biometric auth is available.BiometricPrompt#authenticate(...)
to show biometric dialog to user.Nevertheless, attempt to use it does nothing from user point of view.
Fingerprint.isAvailable()
in JS) results an error: { code: -106, message: BIOMETRIC_NOT_ENROLLED }
Fingerprint.show()
in JS) results the same error. If I remove this check for availability in Java code, I get prompt with PIN, not with face recognition.Possibly, problem may be somewhere in AndroidX internally. SO says:
Android Biometric APIs would only work on the devices which have their biometric features (face,fingerprint, iris) compatible with Android Biometric stack. I have a set of devices with Face feature support, among them only few support Android Biometrics.
Continue research.
@oumaymasalhii
+1 I'm using android 10, and I register my face ID but when I invoke Fingerprint.isAvailable it returns the error BIOMETRIC_NOT_ENROLLED. and when I enroll my fingerprint it return success which means that the plugin doesn't support faceId authentication .
Could you clarify what device do you use? I have the same error with my Xiaomi Mi 10 Lite (M2002J9E). It has face unlock, but plugin does not work with it. So, it doesn't mean that plugin have no FaceID support for Android. Plugin uses standard Android API provided by OS. Looks like this API does not work properly or device vendor did not provide correct implementation.
I also have this issue on a Samsung A11, would love to have this issue fixed if possible. If there's any information I can contribute that would help, I would be happy to do so.
same issue on galaxy tab A7, face recognition enabled and the plugin says BIOMETRIC_HARDWARE_NOT_SUPPORTED, will probably try to use some other plugin for face recognition on android
IIUC this plugin performs as follows:-
@patrikkelmen1 did you find a workng face plugin for Android ?
@petercutting unfortunately not yet (I had other priorities - so I wasn't really looking)
Face ID in Android is not considered a strong biometric for most devices. That means it provides no cipher. We encounter this but in our case, it was just when trying to save the secret that it was failing and we just provided a fallback for such a situation. Now, this is the case in Android 12. I suspect in older versions (like 9) it will just say not supported and the cause will be from the android x library directly.
I have solved the Android Face ID issue by modifying following files:
implementation "androidx.biometric:biometric:1.1.0"
https://developer.android.com/jetpack/androidx/releases/biometric#1.1.0
int error = BiometricManager.from(cordova.getContext()).canAuthenticate(BiometricManager.Authenticators.BIOMETRIC_STRONG);
https://androidx.de/androidx/biometric/BiometricManager.html#canAuthenticate(int)
It does not cover all the devices though, here is the link to track this issue with google. FaceID authentication using BiometricPrompt from AndoidX library cant unlock cipher key
@prajapatijay95 I am facing an issue after doing the above changes
BiometricActivity.java:12: error: package does not exist import androidx.appcompat.app.AppCompatActivity;
How did you resolve this issue in BiometricActivity.java? Did you face the same issue? Can you please help me with it?
@codehack26 Sorry for the late reply. I have not faced this issue. I just made a change to 2 files mentioned in my other comment. Maybe try it with gradle sync.
@prajapatijay95 I did the above two file changes but still getting { code: -106, message: BIOMETRIC_NOT_ENROLLED } can you pls help me how you resolved?
I am using the Android 12 version of Samsung m31 , When I register secret get { code: -106, message: BIOMETRIC_NOT_ENROLLED } can you pls help me how to resolve this?
Bug report
the auth api return -106 error code, even when I turn on the face id
Environment
package version: 4.0.2
test device: android 9
Logs