0

I am trying include facebook authentication into my app. I've created hash key with

keytool -exportcert -alias androiddebugkey -keystore ~/.android/debug.keystore | openssl sha1 -binary | openssl base64

then i've added this hash into appDashboard.

APK without sign works fine, but when i trying buid signed APK from android studio(Build-Generate Signed APK), i have error about mismatched hashkey...

could anybody help me fix this problem? Thx!

kbu
  • 389
  • 2
  • 4
  • 19

1 Answers1

0

Please refer this page: http://developer.android.com/tools/publishing/app-signing.html

Once you obtain your private key(which should be kept very safely and you should not lose it ever, atleast for 25 years) use that key to sign the application and to generate a hash for Facebook dashboard.

Refer this for steps: https://developers.facebook.com/docs/android/getting-started/ Under Create a Facebook App search this command that uses your release(google dev key)

keytool -exportcert -alias <RELEASE_KEY_ALIAS> -keystore <RELEASE_KEY_PATH> | openssl sha1 -binary | openssl base64

That should do it.

Aakash
  • 1,860
  • 19
  • 30
  • One question - if google dev key doesn't exist..it's no sense make signed apk? – kbu May 07 '14 at 14:25
  • Signed apks are used when you upload your app to play store. The debug key that you are using is also signing the application but with the default debug key that comes with Android SDK. That application(debug signed) will not be accepted at Play Store. – Aakash May 07 '14 at 14:31