Reputation: 1904
We are stuck at this point. We are already using the signed APK by installing in multiple devices without any problem, and we've also provided the required key hash in developers.facebook.com which created using the release keystore.
But today we've released the app in google play beta testing, and now after downloading from google play and going to facebook login gives me an error Invalid Key Hash with some key hash value which completely new to me. Different than the key hash we created using the release keystore which we've used to sign the APK.
We are thinking that it might have something to do with the Release Management -> App Signing process which someone else has did something in it, but not sure.
We are already using the apps which have facebook login in google play store production which are working fine but this.
What else need to be done in case of App Signing?
Any help will be greatly appreciated.
Upvotes: 1
Views: 7597
Reputation: 31
In case someone is still facing this in 2021, with the updated Play console, go to "App Integrity" menu, there you'll find "Play App Signing", if it's shown as "enabled", this means your app was signed by Google not your own release key. Copy the keys shown then follow @KunalK answer above. Side note, this also works for services like Google Sign in, which require the SHA-1 and SHA-256 keys.
Upvotes: 0
Reputation: 121
I know this problem. Because, if facebook App installed, we show invalid key-hash. Because different hash key web and facebook App. So, you input code (this code is android java)
facebookloginbutton.setLoginBehavior(LoginBehavior.WEB_ONLY);
setLoginBehavior(Web.only)
you can show another option facebook developer site.
Upvotes: 0
Reputation: 1904
@Dhanumjay, it's fixed now. Thanks to this answer. I also tried to write it down simply from the error message but it didn't work somehow(as it's hard to read, sometimes you may end up typing it wrong)
Upvotes: 4
Reputation: 525
I don't know the exact issue what happening after app signing. I'm also faced the same issue like this for one of my app. Suppose if you are still facing the keyHash issue, simply write down the error keyHash which is showing and paste that keyhash to developers.facebook.com then your problem will be solved.
Upvotes: 0