5

The app that I am working on right now only supports fingerprint authentication but in android 9(pie) the user is asked to select a default biometric preference for all its app. SO if the user selects face_id as a default authentication preference then he would not be able to log into the application. So I just need a way to figure out whats the default biometrics preference of the user so that if the user has selected some other biometric preference rather than fingerprint I can pop up a dialogue at the app startup and ask the user to change its preference.

I am using the new BiometricPrompt API but couldn't find any class or package that gives the default selected biometric preference of the user.

  • _"if the user selects face_id as a default authentication preference then he would not be able to log into the application"_ Do you mean **should** not be able to log into the application? If they are able to select face_id as their default authentication method then presumably the user has enrolled their face on the device. So in that case `BiometricPrompt` should show a face recognition UI. – Michael Feb 08 '19 at 09:52
  • In my case, I just want to authenticate the user using a fingerprint. so if the user has enrolled face_id and set that as a default biometric preference as face I just want to find a way to know the default biometric preference of the user so at the app startup I can show a dialogue to the user telling him that the app only supports fingerprint and for that he needs to change the default preference to fingerprint. is there any way to find out the default selected biometric preference of the user or is there any way to force the user to use fingerprint using biometric prompt API ? – Natansh Pandya Feb 08 '19 at 16:24
  • _"is there any way to force the user to use fingerprint using biometric prompt API?"_ Not currently, no. _"is there any way to find out the default selected biometric preference of the user?"_ I have no idea. – Michael Feb 08 '19 at 16:43
  • @NatanshPandya did you find solution for this? – user3009824 Jan 20 '20 at 11:39

0 Answers0