Home > OS >  firebase App Check won't verify app in firestore in release mode but does in debug mode when ap
firebase App Check won't verify app in firestore in release mode but does in debug mode when ap

Time:09-13

So I implemented App check in my android studio project. And since it was a new app with no users I thought it best to enforce app check from the start. And I have no problem running the app if the app is running on debug mode. But when I create a release APK or bundle I app won't read anything from the Firebase Firestore or storage. What could be the problem? I follow all the steps required. I added the safetyNet dependence in my gradle and initialized the safetyNet Provider in my log in activity before calling any Firebase service.

FirebaseApp.initializeApp(this);
FirebaseAppCheck firebaseAppCheck = FirebaseAppCheck.getInstance();
firebaseAppCheck.installAppCheckProviderFactory(
        SafetyNetAppCheckProviderFactory.getInstance());

Did I miss anything?

CodePudding user response:

If you have used this remove these lines

release {
        minifyEnabled true
}

If not worked then add your SHA1 fingerprint that you get from playstore to the firebase console

CodePudding user response:

add release sha1 key in firebase

  • Related