本文介绍了BiometricPrompt虹膜和面部提示不适用于加密对象身份验证。 #AndroidX的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

问题





  • <$不会提示生物识别虹膜和面部检测c $ c> biometricPrompt.authenticate(** crypto **,hintInfo)调用。



来源参考:




  • 解决方案

    某些设备只有一个外形尺寸,有些具有许多外形。您的应用最终使用哪种尺寸并不完全取决于您;这取决于OEM实施。如中所述,是否不取决于您的代码-OEM决定。 但是,您可以通过在调用<$时指定 CryptoObject 来请求设备对应用使用严格身份验证c $ c> authenticate()。



    您遇到的情况是设备的OEM决定将指纹作为强生物识别的默认设置。因此,当您将 CryptoObject 传递给 authenticate()时,这些设备会向用户显示指纹的UI。


    Issue

    • Biometric authentication iris and face-detection is not prompting withbiometricPrompt.authenticate(**crypto**, promptInfo) call.

    Source reference:

    Device used for testing:

    • Samsung S8 (Android OS 9)

    Steps of Authentication I'm following:

    • val biometricPrompt = BiometricPrompt(...)
    • val promptInfo = BiometricPrompt.PromptInfo.Builder()...
    • biometricPrompt.authenticate(promptInfo) (PFA: option A, B)

    and there is another authentication method which take cipher object to make sure

    Everything worked just as expected with new and older API device support. Until unless realize tested application for other biometric authentication option iris and using face detection.

    If I follow

    • biometricPrompt.authenticate(promptInfo) then application simply display authentication option based on user preference which he has to choose from Device Setting -> Biometric preference.And perform authentication independently. (PFA: option A, B)

    • But if use biometricPrompt.**authenticate**(crypto, promptInfo) then it displays only fingerprint authentication option ONLY. For other preference option iris and face-detection, it does not display anything on authenticate(..) method call. (PFA: option C)

    Question

    • Why other Biometric authentication is not prompting with crypto object authentication.
    解决方案

    Some devices only have one form factor, some have many form factors. Which form factor your app ends up using isn't really up to you; it's up to the OEM implementation. As explained in this blog post, whether a form factor is Strong or Weak doesn't depend on your code -- the OEM decides. However, you can request that a device uses Strong authentication for your app by specifying a CryptoObject when you call authenticate().

    What you are experiencing is that the OEMs of your devices decided to make Fingerprint the default for Strong biometrics. Therefore, when you pass in a CryptoObject to authenticate() those devices show the user the UI for Fingerprint.

    这篇关于BiometricPrompt虹膜和面部提示不适用于加密对象身份验证。 #AndroidX的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!

09-09 08:28