skip to Main Content

We are migrating from Firebase Web SDK to react native Firebase. The phone auth was working well with the Web SDK, however after migrating to react native Firebase we are facing this frustrating issue.

Here is the error message :

Error: [auth/missing-client-identifier] This request is missing a valid app identifier, meaning that Play Integrity checks and reCAPTCHA checks were unsuccessful. Please try again, or check the logcat for more details

Point of error :

auth().signInWithPhoneNumber(num).then((item) => {
    setConfirmation(item);
  });

We are using expo (bare workflow) and this issue is occurring while debugging in the development build as well as in the preview APK. We already had a SHA256 associated with our firebase project, the same key is also uploaded to EAS ( Expo Application Services). We faced no issues with phone login earlier.

  • We tried adding a new SHA-256, redownloaded the google-service.json.
    Using this command
    keytool -list -v -keystore "%USERPROFILE%.androiddebug.keystore" -alias androiddebugkey -storepass android -keypass android)
    Still the issue persists.
  • App is registered with App check in the firebase console with both the SHA 256 (old and new)
  • Tried adding play integrity into build.gradle -> implementation ‘com.google.android.play:integrity:1.3.0’
  • the reCAPTCHA(Surprisingly as this isn’t a play store build) is also not working and we are getting the above mentioned error.

Here are the errors from logcat

  • Failed to initialize reCAPTCHA config: No Recaptcha Enterprise siteKey configured for tenant/project *

  • [SmsRetrieverHelper] SMS verification code request failed: unknown status code: 18002 Invalid PlayIntegrity token; app not Recognized by Play Store. (Right, its a development build)

  • [GetAuthDomainTask] Error getting project config. Failed with INVALID_CERT_HASH 400
    Failed to get reCAPTCHA token with error [There was an error while trying to get your package certificate hash.]- calling backend without app verification

  • [SmsRetrieverHelper] SMS verification code request failed: unknown status code: 17010 null

It seems like it has to do with the SHA keys, but not sure or understanding how exactly.
Please advise.

P.S. : Link for Environment Details, gradles and android files

2

Answers


  1. Chosen as BEST ANSWER

    I only added SHA-256 which was working fine with other libraries thinking one fingerprint would suffice, however after adding SHA-1 it started working as expected.

    They should have mentioned this in detail in the documentation.


  2. Your SHA-1 & SHA-256 fingerprints have probably been changed,
    Open the Google Play Console then select the app you want and then you can find the Play App Signing page under Release > Setup > App Integrity, then add your new fingerprints to your firebase under Project settings.

    Login or Signup to reply.
Please signup or login to give your own answer.
Back To Top
Search