question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. ItĀ collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

[local-authentication] Android should match iOS `authenticateAsync` options where possible

See original GitHub issue

šŸ› Bug Report

Environment

Expo Diagnostics:

Expo CLI 3.17.5 environment info:
    System:
      OS: Linux 5.3 Ubuntu 19.10 (Eoan Ermine)
      Shell: 5.7.1 - /usr/bin/zsh
    Binaries:
      Node: 12.13.1 - ~/.nvm/versions/node/v12.13.1/bin/node
      Yarn: 1.22.4 - ~/.yarn/bin/yarn
      npm: 6.12.1 - ~/.nvm/versions/node/v12.13.1/bin/npm
    IDEs:
      Android Studio: 3.5 AI-191.8026.42.35.5977832

Issue occurs on Android

Steps to Reproduce

The new LocalAuthentication using Android’s BiometricPrompt offers fallback authentication method based on device unlock method (PIN, Password, Pattern). iOS does not do that if fallbackLabel: '' is passed to authenticateAsync(), as stated by the official Expo docs.

Expected Behavior

If fallbackLabel is set to an empty string, do not offer device fallback method like iOS. Also, just like iOS, it would be great to customize the cancelLabel option too.

Issue Analytics

  • State:closed
  • Created 3 years ago
  • Reactions:4
  • Comments:5 (2 by maintainers)

github_iconTop GitHub Comments

7reactions
swayokcommented, Apr 10, 2020

LocalAuthentication.authenticateAsync() for Android lacks configuration badly. For example: I have an app which has its own pin-code and optional biometric auth. I expect LocalAuthentication.authenticateAsync() to ask only for fingerprint/faceid and NEVER fallback to Android’s pass code or anything else. But it is not possible and acually makes this functionality useless in most common cases. It even does not tell that passcode was used in returned result - it just behaves same way as fingerprint: {ā€œsuccessā€: true}.In result app activates fingerprint auth in case when fingerprint test actually failed. And even more absurd situation - with activated fingerprint auth user can avoid fingerprint auth using Android’s passcode… Also there are no possiblity to configure text in biometrics prompt which results in english text in app that does not support english.

I do know that everything I described above is possible to implement because I have apps where this local auth works exactly the way I need - localized and without fallback to passcode.

We all really need Android’s biometric prompt to have options similar to iOS.

1reaction
wesleyrafaelcommented, Apr 6, 2020

I’ve just experienced this problem as well. Hope it can be fixed soon. Also congrats to the team for releasing a new sdk version a few days ago =)

Read more comments on GitHub >

github_iconTop Results From Across the Web

LocalAuthentication - Expo Documentation
expo-local-authentication allows you to use FaceID and TouchID (iOS) or the Biometric Prompt (Android) to authenticate the user with a face or fingerprintĀ ......
Read more >
How to Implement Face ID and Touch ID to React Native App?
In this guide, we will discuss What is Biometric Authentication, How to implement Face ID and Touch ID as biometric authentication in aĀ ......
Read more >
Use Touch ID, Face ID or Pin to Authenticate (Local ... - YouTube
Or any other local authentication method that can be configured. I will also show you how to build a standalone client for iOS...
Read more >
Expo Local Authentication — Face ID and Touch ID - Medium
Authentication. The last step is to authenticate the user using whatever biometric data that is available. The authenticateAsync method returnsĀ ...
Read more >
How to check support of Touch ID, Face Id ,Password and ...
authenticateAsync (); return result; } } }. It will automatically choose between available local authentication (TouchID, FaceID,Ā ...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found